Hi,

How can i get the value of $row['CatName'] without changing the value of in my option.
I have a script to linked the two dropdown box..

Thanks.
This is my code..

Code HTML4Strict:
 
 <script type="text/javascript" charset="utf-8">
  $(function() {
 
    /* For jquery.chained.js */
    $("#subcat").chained("#Cat");
  });
  </script>


Code PHP:
 
	<?php
		echo'<tr>';
			echo'<td align="right"><b>Category <font color=red>*</font>: </b></td>';
			echo '<td>';
			echo '<select id="Cat" name="Cat">';
					echo '<option value=""></option>';
					$cat=mssql_query("Select * from tblCat");
					while($row=mssql_fetch_assoc($cat)){
					echo "<option value='".$row['Catid']."' >".$row['CatName']."</option>";
					}
 
					echo '</select>';
			echo'</td>';
		echo'</tr>';
 
		echo'<tr>';
			echo'<td align="right"><b>Subcategory : </b></td>';
			echo '<td>';
			echo '<select id="subcat" name="subcat">';
				echo '<option value=""></option>';
				$Subcat=mssql_query("Select * from vw_SubCategory");
				while($row=mssql_fetch_assoc($Subcat)){
				echo "<option value='".$row['SubCatName']."' class='".$row['Catid']."' >".$row['SubCatName']."</option>";
				}
				echo '</select>';
			echo'</td>';
		echo'</tr>';		
		?>