Why bother with pseudo ?

Just only have <B>, <I>, and <U> allowed in the database. Also, storing the
<BR> and <P> tags may be important. Be sure not to do things like allowing
font color or face; although relative size might be ok (FONT SIZE="-1") etc.

Siggy

----- Original Message -----
From: "Beau Lebens" <[EMAIL PROTECTED]>
To: "Sridhar Ranganathan" <[EMAIL PROTECTED]>;
<[EMAIL PROTECTED]>
Sent: Thursday, February 01, 2001 5:46 PM
Subject: Re: [PHP-DB] Help Me!


> the way i have attacked a similar situation in the past was to create my
> own formatting system - kind of a pseudo-html set-up, which made use of
> conventions like;
>
> **bold**
> %%italic%%
> __underline__
> !!titlefont!!
>
> etc etc
> then you can save the article directly into the DB, as a text or whatever,
> and when you print it out, do something like;
>
> echo specialTxtFormat($articleBody);
>
> a function which would include a call to nl2br() as well as the
replacement
> of things like
>
> **bold** for <b>bold</b>
>
> enjoy
>
> At 04:13 AM 2/1/01 +0000, Sridhar Ranganathan wrote:
> >Hi Netlanders
> >
> >I have just undertaken a web site construction project. It is a devshed
> >like site that serves articles on various topics. I am using LAMP -
> >Linux/Apache/MySQL/PHP 4. I have a table that contains info about each
> >article. I think I have three options...(or do I have more that I dont
> >know of?!)
> >
> >         1. Store the article body in the database as a LONGTEXT or BLOB
> >         2. Separate plain text file
> >         3. Separate HTML formatted file
> >
> >No matter whether the file is in the database or as a separate file,
> >should it be formatted?
> >If it is plain text, how do I make distinctions between bold text and
> >normal text?
> >(Will fread() using PHP give me '\n' and other such characters too?)
> >If it is HTML formatted, I would loose some control over the look and I
> >would have to copy and paste the plain text article and make it a HTML
file.
> >
> >What should I do?
> >
> >I know I have already asked this question and got some answers. But, when
> >I proceeded with the project, I kept comming back to this one point. A
> >long answer might help. Looking forward to your help.
> >
> >Regards
> >Srinivasan Ranganathan
> >_________________________________________________________________________
> >Get Your Private, Free E-mail from MSN Hotmail at http://www.hotmail.com.
> >
> >
> >--
> >PHP Database Mailing List (http://www.php.net/)
> >To unsubscribe, e-mail: [EMAIL PROTECTED]
> >For additional commands, e-mail: [EMAIL PROTECTED]
> >To contact the list administrators, e-mail: [EMAIL PROTECTED]
>
> --
> Beau Lebens - Web Master
> Insurance My Way, Your Friendly Online Broker
> (08) 9226 5888
> http://www.insurancemyway.com.au/
>
>
> --
> PHP Database Mailing List (http://www.php.net/)
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> To contact the list administrators, e-mail: [EMAIL PROTECTED]
>
>


-- 
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]

Reply via email to