Re: onChange js running a php function

From: Date: Tue, 11 Oct 2005 20:44:30 +0000
Subject: Re: onChange js running a php function
Groups: php.general 
Request: Send a blank email to php-general+get-223933@lists.php.net to get a copy of this message
First, I want to beat everyone to the punch in yelling at you.. "This is not a PHP question!!! RTFM STFU NOOB" or something stupid like that. hah But, maybe it seems like it COULD be a PHP question. And it's definitely relevant to PHP development, so how about we give a REAL answer instead of just yelling. :) Here's what I think.. 1. onChange runs a JS function that checks the value of the SELECT that just changed 2. JS function then redirects to the same script but with scriptname.php?select=selectvalue 3. PHP reads the $_GET['select'] selectvalue and performs appropriate DB pull Voila! (or viola if you're more musical than french) -TG = = = Original message = = = Its been awhile since I tried this so I was wondering if anyone had any luck with this. I need to get a list of tables from a database, which means I have to run a function, I would like to have an onChange event run when I change my selection in a select menu, that would send the value for the select menu to a php function. can that be done? ___________________________________________________________ Sent by ePrompter, the premier email notification software. Free download at http://www.ePrompter.com.

« previous php.general (#223933) next »