Jump to content

Retrieve Trademark symbol from mysql database


mainstreetop

Recommended Posts

Not sure of this belongs in this php forum or in a mySql forum. 

 

I am trying to echo a field from a mySql database that contains a brand name with the 'registered' or 'trademark' symbol already stored.  I'm using htmlentities($BrandName).  The Registered symbols are displaying ok, but the Trademark symbol displays as a small, empty box.

 

First, am I using htmlentities() properly?  Second, does anyone know of why this would be happening?  Thank you.

Link to comment
Share on other sites

Thank you for responding so quickly.  Unfortunatley, those parameters htmlentities($field, ENT_COMPAT, 'UTF-8'); would not display any brands that had any type of symbol.

 

I did use this when initially parsing the XML (via XMLREADER) into the db:

mysql_query("SET NAMES `utf8`");

 

So, I assume this addresses your second point?

 

However, I'm not sure where/how ti use your final suggestion:

use mysql_set_charset

 

Of course, I should probably pose this issue in a mySql forum.

 

Thanks for your help.

Link to comment
Share on other sites

What charset is your database and table in?

CHARSET=latin1

 

What charset is your page in? (<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />)

<meta http-equiv="content-type" content="text/html; charset=UTF-8" />

 

I'm not terribly familiar with character sets but it looks like I'm incompatible here.  Any idea where to make change?

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • 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.