Make a "dynamic drop down list" with using only PHP,HTML
and MySQL..
Answers were Sorted based on User's Feedback
Answer / koushikgraj
Using post back or ajax functionality we can achieve this
| Is This Answer Correct ? | 6 Yes | 2 No |
Answer / sasmitamohanta
<select name="name">
<option value="">Select Name</option>
<?
// make connection to data base
mysql_connect('localhost','root','') ;
//select database
mysql_select_db('mail');
//select all da from 'table' say it ve two colom Id and Name
$sql=mysql_query("select * from table");
//select one by one row data s
while($r=mysql_assoc($sql))
{?>
<option value="<?=$r['Id'];?>"><?=$r['Name'];?></option>
<?}?>
| Is This Answer Correct ? | 5 Yes | 5 No |
Code to upload a file in PHP?
Is it easy to learn php?
What's the difference between using mysql_ functions and pdo?
Explain whether it is possible to share a single instance of a memcache between multiple php projects?
What is the correct line to use within the php.ini file, to specify that 128mb would be the maximum amount of memory that a script may use?
What are getters and setters and why are they important?
What should be the length of variable for SHA256?
How can I reverse sort an array keeping the correlation between the index and value?
2 Answers Rushmore Consultancy,
Which of the delimiter is ASP style?
Any good PHP developer looking for change
what are the errors and when we get that particular errors.and who will give that errors
What is inheritance in php? How many types of inheritance supports php?