Jump to content

Please help on this one - Gurus come this way!


todayme

Recommended Posts

I have gathered the values of two text boxes by using the upon change event for the second drop down box, I have tested it by printing out the values and the variables are holding the right information.  I need to pass this to a script in php to do some other things.  Below is a function I have written in PHP to grab the variables and pass them into new ones and print.

 

function grabvariables()

{

$dbindustry = $cool_industry;

$dbstate = $cool_state;

 

 

Print $dbindustry.'<br>';

Print $dbstate;

}

 

This is the java script that I call on the change event of the second drop down box.

 

<SCRIPT LANGUAGE="javascript">

 

function captureselection()

 

{

 

var locatestate = window.location

var locateindustry = window.location

 

document.Leads.State.value = locatestate

document.Leads.Industry.value = locateindustry

 

var $cool_state = document.Leads.State.value

var $cool_industry = document.Leads.Industry.value

 

function grabvariables()

 

}

                    </SCRIPT> 

 

 

Its not print anything grrrrrrrrrrrr.  The questions I have are this,

 

I now the values are loaded in the variables $cool_state and $cool_industry as I have tested this far, but is that how you call a function that is php?  function grabvariables()  And also if I load variables with java script can I get at them with PHP?

 

 

 

 

 

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.