Welcome Guest, Not a member yet? Register   Sign In
Escaping the trademark symbol with MySQL
#1

[eluser]TWP Marketing[/eluser]
I'm stumped. I want to input the trademark symbol (&tradeWink as part of a textarea input string:
Code:
"This is my trademark: TWP Marketing™ or TWP Marketing™."
however I can only write this to the db one time.

I'm using htmlentities () to encode to the db and html_entity_decode() on extraction from the db. This works on such HTML as the paragraph symbols and less-than/more than, etc. but fails for the trademark symbol.

On the first db operation (insert), the text is stored, correctly escaped (phpMyAdmin shows it to be so). When I read that record back into the same textarea input field, the actual trademark symbol is displayed:

"This is my trademark: TWP Marketing™ or TWP Marketing™."

The generated HTML still shows the properly escaped code for the symbol.

If I update that record, the text stored in the db is truncated just before the first trademark symbol:

"This is my trademark TWP Marketing

Can anyone suggest what is happening here?


Messages In This Thread
Escaping the trademark symbol with MySQL - by El Forum - 03-04-2009, 03:39 PM
Escaping the trademark symbol with MySQL - by El Forum - 03-04-2009, 04:03 PM
Escaping the trademark symbol with MySQL - by El Forum - 03-04-2009, 04:17 PM
Escaping the trademark symbol with MySQL - by El Forum - 03-04-2009, 04:47 PM
Escaping the trademark symbol with MySQL - by El Forum - 03-04-2009, 04:53 PM
Escaping the trademark symbol with MySQL - by El Forum - 03-04-2009, 04:58 PM
Escaping the trademark symbol with MySQL - by El Forum - 03-04-2009, 05:07 PM
Escaping the trademark symbol with MySQL - by El Forum - 03-04-2009, 05:11 PM
Escaping the trademark symbol with MySQL - by El Forum - 03-04-2009, 05:12 PM
Escaping the trademark symbol with MySQL - by El Forum - 03-04-2009, 05:17 PM
Escaping the trademark symbol with MySQL - by El Forum - 03-04-2009, 05:39 PM
Escaping the trademark symbol with MySQL - by El Forum - 03-04-2009, 06:00 PM
Escaping the trademark symbol with MySQL - by El Forum - 03-05-2009, 03:37 AM
Escaping the trademark symbol with MySQL - by El Forum - 03-05-2009, 12:12 PM



Theme © iAndrew 2016 - Forum software by © MyBB