> Hi there everyone,
> I've been looking on Google for PHP Javascript tutorials but I can't find
> any.  I'm new to Javascript but can use PHP for what I need.  I was
> someone would know of a tutorial that would show how to use PHP to get
> datasets which javascript can then use in forms.  For example, say I have
> pulldown boxes, one would have countries - such as UK, USA etc .. If you
> selected the UK it would bring up countries in the UK, and if you select
> country the third pulldown would show the cities in that country (This is
> just an example to hopefully explain what I need) but I don't want the
> to refresh everytime I select an option which it does if you just use

Since they are two seperate languages, all you can really do is use PHP to
write dynamic Javascript or assign values to javascript variables with
php..  if you want the drop downs to be dynamic then you'll need to write a
function that makes a database call, gathers all the data and then writes
it to static arrays in a file that you can then read with Javascript and
create the drop downs from the arrays.

They are seperate, don't think of them as being able to work together to
much.  except that you can build JS using PHP.


PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to