GetSimple Support Forum
page content storage - Printable Version

+- GetSimple Support Forum (http://get-simple.info/forums)
+-- Forum: GetSimple (http://get-simple.info/forums/forumdisplay.php?fid=3)
+--- Forum: Developer Discussions (http://get-simple.info/forums/forumdisplay.php?fid=8)
+--- Thread: page content storage (/showthread.php?tid=4486)



page content storage - Carlos - 2013-03-16

(This is something that some users have requested several times in the past...)

I suggest that for some future GS release the content is not stored with addslashes and htmlentities, but as raw HTML.

Of course this would require many plugins to be adapted, so it would be better doing it in a major release (version 4 maybe?).

For backwards compatibility with old page data files without having to run an upgrade script, I can think of 2 ways to handle it:

A) Have a new field, e.g. format. For example:
<format>1</format> = pure HTML
<format>0</format> (or empty or no field) = old-style addslashes+htmlentities

or

B) Use a new field for raw html, e.g. html or htmlcontent.
GS would check if that field exists, else it would use the content field (decoding, etc.)


RE: page content storage - shawn_a - 2013-03-17

In XML do you not have to escape ?


RE: page content storage - Carlos - 2013-03-17

AFAIK not needed if it's between <![CDATA[ and ]]>


RE: page content storage - shawn_a - 2013-03-17

So is this a pre simplexml extended thing that was done ?


RE: page content storage - Carlos - 2013-03-18

Chris only knows.


RE: page content storage - shawn_a - 2013-03-18

Hmm we can add a new flag or change the file version and change this in the future.
I notice we are usin cdata for everything. Odd


RE: page content storage - shawn_a - 2013-07-30

This will also allow us to save xml files as true utf-8, not encoded junk.


RE: page content storage - shawn_a - 2013-07-30

https://github.com/GetSimpleCMS/GetSimpleCMS/issues/618