Detailed description goes below.
The Requirement
I'm developing a Blogging page which includes designing both front and back end. Using MVC WebAPI as service and MySQL to store data. My blog page requires to be presented in 2 different layouts as of now, and in future I may add more layouts for the same page. The challenge here is designing the database table since contents for different layouts will be presented in different formats, e.g.-3 paragraphs and 2 images in first layout, 5 paragraphs and 3-4 images in second layout.
What I've tried
After going through various concepts "Storing the entire HTML content in database" sounded the most feasible solution since it's quite straightforward approach to do. However this approach isn't feasible for me since:
- It means hard coding the data-->Resulting hard to modify in future.
- I've plans to develop mobile apps in future in which case this HTML data would be meaningless for me.
What I'm planning
To create a MySQL table with various columns for both paragraphs and images(P1,P2,P3,IMG1,IMG2...etc), but again to me this approach looks not so future proof considering modifying the table would be hard in future.
So here I come to get some nice adaptive solutions to design the table as per my requirement. The attached screenshot is an initial view of my first blog description page.
TIA.
Regards,
Dash
