Board index   FAQ   Search  
Register  Login
Board index php forum :: HTML JavaScript

Passing arrays to a javascrpt

Javascript coding ..

Moderators: macek, egami, gesf

Passing arrays to a javascrpt

Postby popeye » Fri Apr 15, 2005 8:51 pm

Based on which option selected in the first dropdown <select> menu, I need to change the option list of the second <select> dropdown menu.
I need this to be able to collect and/or change State and County information using <select> and dropdown menus.
Is it possible to pass back and forth a php created array to a javascript function used with onchange property of <select>?

Thanks.
User avatar
popeye
New php-forum User
New php-forum User
 
Posts: 120
Joined: Sat Jan 03, 2004 7:06 pm
Location: New York, NY

Postby ruturajv » Sun Apr 17, 2005 7:42 pm

yes that is possible,
only thing is u need to populate javascript arrays for all the options.
then using javascript populate the select list based on the array[javascript] and your condition.
User avatar
ruturajv
php-forum Super User
php-forum Super User
 
Posts: 1280
Joined: Sat Mar 22, 2003 9:42 am
Location: Mumbai, India


Return to JavaScript

Who is online

Users browsing this forum: No registered users and 1 guest

Sponsored by Sitebuilder Web hosting and Traduzioni Italiano Rumeno and antispam for cPanel.

cron