Gossamer Forum
Home : Products : DBMan : Discussions :

html in records

Quote Reply
html in records
I apologize if this topic has already been covered.

Is it possible to put html in a field in the database and have it it displayed as the browser would see it in the database results?

Thanks in advance for your help.

Seth

Quote Reply
Re: html in records In reply to
You mean like <b>text</b> becoming text?

Or <b>text</b> becoming <b>text</b>?

If the former, then DBMan should already work this way, if the later, them you will need to customise html.pl accordingly:

In sub html_record, add the the following under my (%rec) = @_;:

$rec{'FIELD_WITH_HTML'} =~ s/>/&gt;/g;
$rec{'FIELD_WITH_HTML'} =~ s/</&lt;/g;


- Mark


Astro-Boy!!
http://www.zip.com.au/~astroboy/
Quote Reply
Re: html in records In reply to
Thanks for the quick response, Mark. The latter. I'll give it a shot.

Thanks again,
Seth