Link to home
Start Free TrialLog in
Avatar of Johnny
JohnnyFlag for United States of America

asked on

on load populate combo box from php value

here my problem
i have a combobox that populates schools..i want topass the value of this school to a php page that has a combobox init and if the value = a value then it selects that value.

ie

Wittenberg University
University of Louisville
West Liberty State College

user has picked school 2 from previous page. and this value is in $school_pick as "University of Louisville"

how do i get an onload for the combo box to populate the combo box to reflect that please

thank you for any help and code you may propvide
---------------------------------------
i thought i could do this but its not working
<body bgcolor="#ffffff" link="#5e2f2f" text="#000000" vlink="#666666"  onLoad='document.form.School.selectedIndex = "2";'>

<P><strong> College: &nbsp;
    <SELECT name='School' size='1' onChange='reloadCities(this.selectedIndex);' onclick='enableLoft();'>
      <OPTION value='0'></option>
      <OPTION value='Wittenberg University'>Wittenberg University</option>
      <OPTION value='University of Louisville'>University of Louisville</option>
      <OPTION value='West Liberty State College'>West Liberty State College</option>
    </select>
&nbsp; &nbsp;&nbsp; &nbsp;
ASKER CERTIFIED SOLUTION
Avatar of smilyjf
smilyjf
Flag of Australia image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of Johnny

ASKER

thank you
Avatar of Johnny

ASKER

thx