Re: Radio Buttons

From: Date: Sun, 07 Jan 2001 16:34:55 +0000
Subject: Re: Radio Buttons
References: 1  Groups: php.db 
Request: Send a blank email to php-db+get-5677@lists.php.net to get a copy of this message
It depends on your database design. Assuming you have only one table of questions ("question") and can have many questions, I think you should store the value resolved itself like "Needs Improvement", this way you do not need a translation table of the form 0=>"Needs Improvement". You can also create only one "Answers" table with all possible results. You may have, say 7 possible answers. Imagine "Needs Improvement" is the 4th record and your present radio button only has three choices, its values could not be 0,1,2 but you must set the right value ( stored ) to each option. HTH Jayme. http://www.conex.com.br/jjeffman -----Mensagem Original----- De: Mark McCray <mm@tbwachiat.com> Para: <php-db@lists.php.net> Enviada em: domingo, 7 de janeiro de 2001 13:45 Assunto: [PHP-DB] Radio Buttons > Hello everyone, > I'm wondering what the best way to store values from a set of radio buttons > is? > > I'm working part of an employee website where employee reviews are handled. > Most questions will have a set of radio buttons for each questions, with the > choices of either "Needs Improvement", "Meets Standard", or "Exceeds > Standard". I guess I could store them with numbers, 0, 1, or 2. I'm just > wondering when I need to edit an employee's review, how do you go about > displaying the correctly check radio button based on what the database > stores. > > > TBWA\CHIAT\DAY > MARK S. McCRAY > financial systems analyst > > 488 MADISON AVE > NEW YORK CITY, NY > ZIP: 10022-5702 > TEL: 212.804.1114 > FAX: 212.804.1200 > > mm@tbwachiat.com > AIM: MarkSMcCray > >

« previous php.db (#5677) next »