Oh no! Where's the JavaScript?
Your Web browser does not have JavaScript enabled or does not support JavaScript. Please enable JavaScript on your Web browser to properly view this Web site, or upgrade to a Web browser that does support JavaScript.
Not a member yet? Click here to register.
Forgot Password?

Radio Button

Asked Modified Viewed 1,519 times
C
Catzenjaeger
C
  • Senior Member, joined since
  • Contributed 408 posts on the community forums.
  • Started 137 threads in the forums
  • Started this discussions
asked
Senior Member

since hours i try to change a normal text field to change to a yes/no radio button. I want this store in my database
I can make this so:

   echo "<input type='radio' name='figure_limitation' value='Yes' />";
   echo "<input type='radio' name='figure_limitation' value='No' />";

and the data there stored in database but when i edit the data the radio buttons are empty

i don't know how i can make this correct .. i think checked is the reason but i have no luck with this

here my try:

   echo "<input type='radio' name='figure_limitation' value='Yes' />";
   echo "<input type='radio' name='figure_limitation' value='No' />";
   if ($figure_limitation == "Yes") {
      echo "<input type='radio' name='figure_limitation' value='Yes' CHECKED />";
   }


can anyone help? Thanx so much
Edited by N/A on 01-05-2016 08:09,
0 replies

2 posts

F
Falk
F
Falk 131
Need help?, Having trouble?
• View our Documentation for Guides, Standards and Functions
• Name and Organize your Topics and Content correctly in the corresponding Forums for best support results
• Attaching Log Files and Screenshots when reporting issues will help
• Provide with an URL to live example if one exists
• Please read the How to Report an Error post
• Please read and comply with the Code of Conduct

(¯·._.·(¯°·._.·°º*[ Project Manager ]*º°·._.·°¯)·._.·¯)
  • Super Admin, joined since
  • Contributed 6,201 posts on the community forums.
  • Started 639 threads in the forums
  • Answered 11 questions
answered
Super Admin

$figure_limitation
need to be defined from a MySQL result. start with echo $figure_limitation; and see if you even have it pulled form your database.
0 replies
C
Catzenjaeger
C
  • Senior Member, joined since
  • Contributed 408 posts on the community forums.
  • Started 137 threads in the forums
  • Started this discussions
answered
Senior Member

Hi
thank for response
$figure_limitation is defined and have a result ( yes or no) and will fill in database.
My problem is, when i edit the data-sheet both checkboxes are empty. I don't know hoe can make this that i see what sorted in database. I have google since hours and try different variations but non works sad
i give up

the normal text box variant works 100%

//Limited Edition (locale 450)
echo "<td width='80' class='tbl'>".$locale['figure_450'].":</td>\n";
echo "<td class='tbl'><input type='text' name='figure_limitation' value='".$figure_limitation."' class='textbox' style='width:380px;' /></td>\n";
echo "</tr>\n<tr>\n";
0 replies

Labels

None yet

Statistics

  • Views 0 views
  • Posts 2 posts
  • Votes 0 votes
  • Topic users 2 members

2 participants

F
F
Falk 131
Need help?, Having trouble?
• View our Documentation for Guides, Standards and Functions
• Name and Organize your Topics and Content correctly in the corresponding Forums for best support results
• Attaching Log Files and Screenshots when reporting issues will help
• Provide with an URL to live example if one exists
• Please read the How to Report an Error post
• Please read and comply with the Code of Conduct

(¯·._.·(¯°·._.·°º*[ Project Manager ]*º°·._.·°¯)·._.·¯)
  • Super Admin, joined since
  • Contributed 6,201 posts on the community forums.
  • Started 639 threads in the forums
  • Answered 11 questions
C
C
  • Senior Member, joined since
  • Contributed 408 posts on the community forums.
  • Started 137 threads in the forums
  • Started this discussions

Notifications

Track thread

You are not receiving notifications from this thread.

Related Questions

Not yet