>>  Site Map >>  Forums >>  Modules

Forum module - topics in forum:



Modules - Get help on installing any module or add-on here



Yes & No Radio buttons help

Hello all

I am after a little help with the yes and no boxes in the edit user profile my trouble is i have created a mod to enable or disable private messages from the v3 arcade now all my coding works ok and the user profile in the database is updated when you select yes or no however in the edit user profile page the radio buttons do not remember the selected option can anyone tell me what controls that so it remebers the users last selection

example of problem:



Cheers






Am I understanding you correctly, the information in the database is changing?






Yes mate the information in the database is changing?






Here is an example of the the code for allow BBCode. This should give you an idea of what the code should look like. for your code. Without seeing your code it's a bit difficult to tell you whats wrong.
Code: :
   echo "<tr><td bgcolor='$bgcolor2'><b>"._ALLOWBBCODE."</b></td><td bgcolor='$bgcolor3'>";
   if ($userinfo['user_allowbbcode'] == 1) {
       echo "<input type=\"radio\" name=\"user_allowbbcode\" value=\"1\" checked>"._YES." &nbsp;"
      ."<input type=\"radio\" name=\"user_allowbbcode\" value=\"0\">"._NO."";
   } elseif ($userinfo['user_allowbbcode'] == 0) {
       echo "<input type=\"radio\" name=\"user_allowbbcode\" value=\"1\">"._YES." &nbsp;"
      ."<input type=\"radio\" name=\"user_allowbbcode\" value=\"0\" checked>"._NO."";
   }
   echo "</td></tr>";
But this should at least point you in the right direction.






Thanks for your advice mate but i have found the problem i forgot to add the check command silly me lol

Cheers anyway




Attention! You are currently viewing sitemap page!
We strongly suggest to look at original content

Search from web

Valid HTML 4.01 Valid CSS