Jump to content

mysql_query(SET NAMES) display problem


co.ador

Recommended Posts

I SET NAMES as below and it won't display the $content ['shoename'];

 

$result = mysql_query("SET NAMES 'utf-8';", $query, $connection);

 

$query = "SELECT id, shoename, image,  price, moreinfo, shoename_id
FROM shoes
WHERE
shoename_id= " . (int) $_GET['menu'];
echo $query;
$result = mysql_query("SET NAMES 'utf-8';", $query, $connection); 

while ($content = mysql_fetch_array($result)) {
echo'<table width="50%" border="0" cellspacing="0" cellpadding="0" bordercolor="#99FF33" bgcolor="#FFFFFF" id="restauranttable">';
  echo "<table width=\"202\" border=\"0\" cellspacing=\"0\" cellpadding=\"0\" bordercolor=\"#FF0033\" bgcolor=\"#FFFFFF\" style=\"float:left; position:relative; left:194px; top:220px;\"></td><td width=\"95\"><table width=\"96%\" height=\"217\">
      <tr><tr><td height=\"10\"><img src=\"../images/spacer.gif\" width=\"95%\" height=\"7\" style=\"position:relative; left:7px;\"/></tr>
        <td bordercolor=\"#666666\" bgcolor=\"#D83607\" height=\"16\" style=\"font-size:14px; font-weight:bold;\"><a href=\"itemdetails2.php?id=". $content['id'] ."& shoenamename=".$content['shoename']."\"><div class=\"letras\" align=\"center\" style=\"background-image:url(../images/titleplate.gif);\">" . $content['shoename'] . "</div></a></td>
      </tr>
      <tr>

Link to comment
https://forums.phpfreaks.com/topic/170327-mysql_queryset-names-display-problem/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

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