Jump to content

Formatting field from database


ethoemmes

Recommended Posts

Hi,

I have a script which pulls information from a mySQL database. The field contains descriptions of books. The output is formatted within a <p class="description"> tag. The data in the database has coding within the field which determines quote's so for example:

databasefield = "This is normal text which I would like to format as above. [quote]The database stores quotes in these square brackets[/quote] Normal text again etc etc"

What I would like to do is apply a different style to the text within the square brackets. Whats the best way of achieving this?

Thanks

Edgar
Link to comment
https://forums.phpfreaks.com/topic/21186-formatting-field-from-database/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.