Re: [nyphp-talk] Textarea formatting

2006-10-27 Thread Chris Shiflett
AbraCadab Ra wrote: > before inserting into the database I encode the data using the > htmlspecialchars() function. > > $encReq = htmlspecialchars($req, ENT_QUOTES); > > when I'm displaying it back to the user i had to use the > following function to convert it back into HTML. Sounds like you're

Re: [nyphp-talk] Textarea formatting

2006-10-27 Thread AbraCadab Ra
I had a similar issue and this is the solution i came up with. I have often wondered if this is the right way of doing it or not, but I'm by far not a PHP guru, just learning. before inserting into the database I encode the data using the htmlspecialchars() function. $encReq = htmlspecialchars($req

Re: [nyphp-talk] Textarea formatting

2006-10-19 Thread David Krings
Hi, you can't display tab in HTML and the textarea box takes just plain ASCII. So any fancy spacing, indenting or such will either be stripped or shown as single spaces. And HTML also cannot display an arry of simple white space. You would need to convert that to non-breaking spaces. But i

Re: [nyphp-talk] Textarea formatting

2006-10-19 Thread David Krings
And for XHTML that would be . Felix Shnir wrote: > Well, if you are talking about displaying in HTML then you should > replace \n\r with a > > Felix. ___ New York PHP Community Talk Mailing List http://lists.nyphp.org/mailman/listinfo/talk NYPHPCon 2

Re: [nyphp-talk] Textarea formatting

2006-10-19 Thread Cliff Hirsch
Behalf Of Ben Sgro (sk) Sent: Thursday, October 19, 2006 1:32 PM To: NYPHP Talk Subject: Re: [nyphp-talk] Textarea formatting Ken, Great, that's exactly what I need. Thanks all! - Ben - Original Message - From: "Ken Robinson" <[EMAIL PROTECTED]> To: "NYPHP Talk&qu

Re: [nyphp-talk] Textarea formatting

2006-10-19 Thread Ben Sgro (sk)
Ken, Great, that's exactly what I need. Thanks all! - Ben - Original Message - From: "Ken Robinson" <[EMAIL PROTECTED]> To: "NYPHP Talk" Sent: Thursday, October 19, 2006 2:28 PM Subject: Re: [nyphp-talk] Textarea formatting At 02:10 PM 10/19/20

Re: [nyphp-talk] Textarea formatting

2006-10-19 Thread Ken Robinson
At 02:10 PM 10/19/2006, Ben Sgro (sk) wrote: >Felix, > >Sure, that is helpful, but what about tabs, lists and all the other >elements that could exist in an email message. >I'm looking for a canned function or class that will do the work. You can try displaying the text between tags. Ken

Re: [nyphp-talk] Textarea formatting

2006-10-19 Thread Ben Sgro (sk)
", $cellSet[0]['info']); - Original Message - From: Felix Shnir To: NYPHP Talk Sent: Thursday, October 19, 2006 1:24 PM Subject: Re: [nyphp-talk] Textarea formatting Well, if you are talking about displaying in HTML then you should replace \n\r with a Fe

Re: [nyphp-talk] Textarea formatting

2006-10-19 Thread Felix Shnir
Well, if you are talking about displaying in HTML then you should replace \n\r with a Felix.On 10/19/06, Ben Sgro (sk) < [EMAIL PROTECTED]> wrote:Hello all,I have a textarea field that can .. store text. I'm using it to save emails for example w/a form.I grab the posted data and call addslashes( )

Re: [nyphp-talk] Textarea formatting

2006-10-19 Thread Ken Robinson
At 12:47 PM 10/19/2006, Ben Sgro (sk) wrote: Hello all, I have a textarea field that can .. store text. I'm using it to save emails for example w/a form. I grab the posted data and call addslashes( ) then stick it into the database, varchar(1024). (this is a calendar app for my own use). Now, wh

[nyphp-talk] Textarea formatting

2006-10-19 Thread Ben Sgro (sk)
Hello all, I have a textarea field that can .. store text. I'm using it to save emails for example w/a form. I grab the posted data and call addslashes( ) then stick it into the database, varchar(1024). (this is a calendar app for my own use). Now, when I pull it out, its not formatted and disp