Jump to content
MakeWebGames

Peterisgb2

Members
  • Posts

    1
  • Joined

  • Last visited

Everything posted by Peterisgb2

  1. well i tired to use this colour change but it would not work, so i decided to custom it so that the users can tottaly choose there colour   function color_change() { global $ir,$c,$userid,$h; print "<h3>Name Colour Change</h3> <form action='preferences.php?action=colorchange2' method='post'> Name Colour: <input type='text' name='username_color' value='{$ir['username_color']}' /> <input type='submit' value='Change name color' /></form>"; } function do_color_change() { global $db,$ir,$c,$userid,$h; if($_POST['username_color'] == "") { print "You did not enter a colour. "; } else { $_POST['username_color']=str_replace(array("<", ">", "\\\'"), array("<", ">", "'"), $_POST['username_color']); $db->query("UPDATE users SET username_color='{$_POST['username_color']}' WHERE userid=$userid"); print "Username colour changed!"; } }
×
×
  • Create New...