Ok guys ive being playing around with these codes and stuff but still cant get it to work
index.php
genproc.php
and in sql ive added this
what can i do to make this code work
index.php
Code:
$showavatar = mysql_fetch_array(mysql_query("SELECT showavatar FROM ibwf_users WHERE id='".$uid."'"));
Code:
if($showavatar[0]=="1") { $avlink = getavatar($item[2]); if ($avlink!=""){ echo "<img src=\"$avlink\" height=\"25\" width=\"25\" alt=\"avatar\"/>"; }else{ echo "<img src=\"/images/nopic.jpg\" height=\"25\" width=\"25\" alt=\"avatar\"/>"; } }
Code:
echo "<small>Show Avatar online?:</small> <select name=\"showavatar\" value=\"$showavatar[0]\">"; if($showshout[0]=="1"){ echo "<option value=\"1\" selected=\"1\">Yes</option>"; }else{ echo "<option value=\"1\">Yes</option>"; } if($showavatar[0]=="0"){ echo "<option value=\"0\" selected=\"0\">No</option>"; }else{ echo "<option value=\"0\">No</option>"; } echo "</select><br/><br/>";
Code:
$showavatar = $_POST["showavatar"]; $res = mysql_query("UPDATE ibwf_users SET showavatar='".$showavatar."' WHERE id='".$uid."'");
Code:
showavatar int 100 default 1
Comment