Hi,
You seem to be proceeding in right direction.
I have the following suggestions:
a) The names $rs_modify and $row_rs_modify are very confusing.
Is this the list of all records in tech group table.
If yes, then $rs_tech_group is more meaningful.
b) As I understand, you want to show the current value in form
as selected in the list menu.
If so, then you should read the current value in form into a
variable like $current_tech_group and then compare against
each value in the list menu.
Your code
Code: Select all
<option value="<?php echo $row_rs_modifyї'tech_group']?>"<?php if (!(strcmp($row_rs_modifyї'tech_group'], $row_rs_modifyї'tech_group']))) {echo "SELECTED";} ?>><?php echo $row_rs_modifyї'tech_group']?></option>
should be something like:
Code: Select all
<option value="<?php echo $row_rs_modifyї'tech_group']?>"
<?php if ($row_rs_modifyї'tech_group'] == $current_tech_group)
{echo "SELECTED";} ?>
><?php echo $row_rs_modifyї'tech_group']?></option>
If you still have some problems, please paste your entire code
including the queries to select the form record and the list menu values.
Ajay