I'm building a custom CMS system that will store articles.
What is the correct way to store the article in the db? Given that an article may consist of a single paragraph or any number of paragraphs and may contain images it doesn't seem practical to store each paragraph in a distinct field of the db.
I have looked at how Wordpress stores posts and it seems to lump the raw html in a single field `post_content'. Is this an accepted method? The disadvantage I see with this method is that for each article any html mark-up is also stored. If I only stored the raw text then the dynamic page which displsys the article would only contain the html mark-up just once. But then how to derentiate between paragrpahs and images?
Any thoughts?
Thank you.