Hi guys, I'm new to PHP and AJAX/JS so I apologize if this is an incredibly obvious error.
I'm in the process of creating multiple listboxes that are chained together for an advanced search form. I have everything working for the ajax and the issue I'm running into is when I try to pass a PHP variable to a JS function. I've searched multiple forums and read multiple posts about this issue but cannot figure out what's going on. I know that everything else is working because if I pass in something besides my PHP variable things come out fine.
The method is called whenever the selection changes:
<select multiple size=5 name="Package" style="width: 15em;" onchange='setPa ckage($partType , this.value)'>
It's the "$partType" that I'm having issues with. I've tried passing it about a dozen different ways with no luck and I'm not sure how to debug the issue. The function is pretty basic:
function setPackage(str, blah)
{
....
}
Any advice would be appreciated.
-Melinda
I'm in the process of creating multiple listboxes that are chained together for an advanced search form. I have everything working for the ajax and the issue I'm running into is when I try to pass a PHP variable to a JS function. I've searched multiple forums and read multiple posts about this issue but cannot figure out what's going on. I know that everything else is working because if I pass in something besides my PHP variable things come out fine.
The method is called whenever the selection changes:
<select multiple size=5 name="Package" style="width: 15em;" onchange='setPa ckage($partType , this.value)'>
It's the "$partType" that I'm having issues with. I've tried passing it about a dozen different ways with no luck and I'm not sure how to debug the issue. The function is pretty basic:
function setPackage(str, blah)
{
....
}
Any advice would be appreciated.
-Melinda
Comment