Hi,

I have two tables city and country
+-----------+-------------+------+-----+---------+----------------+
| Field     | Type        | Null | Key | Default | Extra          |
+-----------+-------------+------+-----+---------+----------------+
| id        | int(5)      |      | PRI | 0       | auto_increment |
| city      | varchar(35) |      | MUL |         |                |
| countryid | int(5)      |      | MUL | 0       |                |
+-----------+-------------+------+-----+---------+----------------+
3 rows in set (0.00 sec)

mysql> desc country;
+---------+-------------+------+-----+---------+----------------+
| Field   | Type        | Null | Key | Default | Extra          |
+---------+-------------+------+-----+---------+----------------+
| id      | int(5)      |      | PRI | 0       | auto_increment |
| country | varchar(35) |      | MUL |         |                |
+---------+-------------+------+-----+---------+----------------+
2 rows in set (0.00 sec)

I am trying to write a php script that does the following.
In an html page I have two dropdowns one country which will get the data
from the country table and city which should get the data from the city
table based on the one selected from the country drop down.  I do not want
to use a submit button.  I use a javascript and using onChange pass the
country.id to the javascript but do not know how to pass it back to the
php script.  Any pointers

Adrian

-- 
=================== 
Adrian D'Costa 
[EMAIL PROTECTED] 
www.pcsadvt.com
===================


---------------------------------------------------------------------
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/           (the list archive)

To request this thread, e-mail <[EMAIL PROTECTED]>
To unsubscribe, e-mail <[EMAIL PROTECTED]>
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php

Reply via email to