Create an account

Very important

  • To access the important data of the forums, you must be active in each forum and especially in the leaks and database leaks section, send data and after sending the data and activity, data and important content will be opened and visible for you.
  • You will only see chat messages from people who are at or below your level.
  • More than 500,000 database leaks and millions of account leaks are waiting for you, so access and view with more activity.
  • Many important data are inactive and inaccessible for you, so open them with activity. (This will be done automatically)


Thread Rating:
  • 350 Vote(s) - 3.52 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Is it ok to save large html content in the database when building a CMS

#1
I'm building a site which mainly has articles and I'm using **ASP.NET MVC 5** framework and SQL server.

I want to handle the site as a Content Management System, where I can add, edit these article content.
I'm planning to use a **Rich text editor** (TinyMCE) to handle content of an article (Add and edit text, images, links etc.).

In this approach I'll have to save the html of a whole article page in a database column, like given below.

*Article table columns*


- ArticleId
- ArticleTitle
- CreatedDate

- Content (The html of the whole article, generated by the text editor)

I searched about saving html in database and I found mixed responses.
I would want to know is this conceptually correct in a general perspective and in an ASP MVC perspective. and I'm open to alternative approach.
Reply

#2
After researching a lot on this,

Lots of CMSs save **HTML content generated from Rich Text Editors** in databases as HTML (Even Wordpress [
Why does Wordpress stores HTML in the Database][1]).


[1]:

[To see links please register here]



So the below approach is pretty acceptable.

Article table columns

- ArticleId
- ArticleTitle
- CreatedDate
- Content (The html content, generated by the text editor)

When rendering the page, use a template for the Article page, which will handle the layout of the page.
Reply



Forum Jump:


Users browsing this thread:
1 Guest(s)

©0Day  2016 - 2023 | All Rights Reserved.  Made with    for the community. Connected through