On Sat, 11 Mar 2006 12:48:27 +0100
Bruno Dumon <[EMAIL PROTECTED]> wrote:

> On Fri, 2006-03-10 at 19:35 +0100, Moritz Kobel wrote:
> > Hi,
> > 
> > i'm writing a simple content management system with the html-editor
> > tiny-mce instead of htmlarea. on one page there are multiple
> > content-fields possible, so i generate the template & definition
> > file with data from a sql database.
> > when i fill up the inital-value with html code from the database
> > all the html-tags are removed.
> > 
> > can somebody give me a hint how to solve this problem? i found no
> > solution seeking the mailinglist and asking google.
> 
> If the fields use the string datatype, then make sure the HTML is in
> escaped form, i.e. something like &lt;html&gt;&lt;body&gt; ...
> 
> Not sure if this is the problem though, as you would need to do
> special effort for having it not escaped.
> 

Thank you... it works!

if somebody has the same problem:
using postgresql i've this part in the query:

[...]
replace(replace(encode(v.content,'escape'),'&lt;','&amp;lt;'),'&gt;','&amp;gt;')
as content
[...]

(v.content is a bytea)

-moritz



---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to