Re: [PHP] Re: htmlentities

2011-09-14 Thread Johan Lidström
On 13 September 2011 23:01, Shawn McKenzie wrote: > On 09/13/2011 01:38 PM, Ron Piggott wrote: > > > > Is there a way to only change accented characters and not HTML (Example: > ) > > > > The syntax > > > > echo htmlentities( > stripslashes(mysql_result($whats_new_result,0,"message")) ) . "\r

[PHP] Re: htmlentities

2011-09-13 Thread Shawn McKenzie
On 09/13/2011 01:38 PM, Ron Piggott wrote: > > Is there a way to only change accented characters and not HTML (Example: >) > > The syntax > > echo htmlentities( stripslashes(mysql_result($whats_new_result,0,"message")) > ) . "\r\n"; > > is doing everything (as I expect). I store breakin

[PHP] Re: HTMLEntities as NUMERIC for XML

2008-11-25 Thread Al
[EMAIL PROTECTED] wrote: After reading this: http://validator.w3.org/feed/docs/error/UndefinedNamedEntity.html (all praise W3.org!) I am searching for a PHP library function that will convert all my &abc; into { I have a zillion of these things from converting stupid MS Word characters into

Re: [PHP] Re: HTMLEntities as NUMERIC for XML

2008-11-25 Thread Ashley Sheridan
On Tue, 2008-11-25 at 17:09 +, [EMAIL PROTECTED] wrote: > I already had a function to go from weird MS-Word characters to HTML > Entities, which I was putting into the DB as such. > > > > In retrospect, that function should have been called at output... Actually, I > knew it should have,

[PHP] Re: HTMLEntities as NUMERIC for XML

2008-11-25 Thread ceo
I already had a function to go from weird MS-Word characters to HTML Entities, which I was putting into the DB as such. In retrospect, that function should have been called at output... Actually, I knew it should have, but convincing my co-workers was the proverbial brick wall, so I cheated

[PHP] Re: htmlentities()

2004-09-08 Thread Paul Birnstihl
Anthony Ritter wrote: bold"; echo htmlentities($str); ?> .. // outputs: A 'quote' is bold Not sure why the I am still getting the tags and spaces after the call to htmlentities(). Check out the source code of the output. Maybe you want the strip_tags() function ? -- PHP General Mailin

Re: [PHP] Re: htmlentities and foreign characters from MS Word

2004-09-06 Thread Octavian Rasnita
You could store those texts as binary in MySQL... - Original Message - From: "Monty" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Monday, September 06, 2004 11:07 AM Subject: [PHP] Re: htmlentities and foreign characters from MS Word > That did it! It

[PHP] Re: htmlentities and foreign characters from MS Word

2004-09-06 Thread Monty
That did it! It seems that my version of MySQL doesn't support Unicode encoding, only the various ISO encodings. So, I guess this translation is necessary before storing all text in the DB so foreign characters aren't broken when I retrieve them from the DB. Thanks! I2eptilex wrote: > > Well i

[PHP] Re: htmlentities and foreign characters from MS Word

2004-09-05 Thread I2eptileX
Well it seems you have a UTF-8 encoded text after your function. Use iconv to change it. See http://de3.php.net/manual/en/ref.iconv.php . try doing this with your array before inserting it into the DB foreach($insert_array as $key => $var){ $new_arr[$key] = iconv("UTF-8", "ISO-8859-1", $v

[PHP] Re: Htmlentities and Newlines?

2002-09-28 Thread Christopher J. Crane
$Something = str_replace("\n", "", $Something); This is old but still works well. "Andre Dubuc" <[EMAIL PROTECTED]> wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... > Perhaps I don't understand the use of 'htmlentities' too well, but I would > like newlines to be retained/inserted int