问题
I want to add some images between the texts. I stored texts in sqlite db. How can I determine the right location of images in texts. For example, I have 5 paragraphs in one lesson that I stored all those paragraphs in one cell of a row in db named body_of_lesson. Now I want to add an image after line 3 of first paragraph and 1 image after second paragraph. How can I determine these locations and add images into the locations? In other lessons might be vary the locations. I saved texts as HTML formatted into the database.
Please help me !!
回答1:
use image ref in your html. e.g. <a href="file:///**", which ** is the image path stored in sqlite.
来源:https://stackoverflow.com/questions/40330547/how-to-add-images-within-texts-that-stored-in-sqlite-in-android