Try using single quotes, as in:

<select name="category" onchange="showSubcategory(document.getElementById('category').value)">
Michael Horowitz wrote:
Having trouble so I went to testing with one element like this

<select name="category" onchange="showSubcategory(document.getElementById("category").value)"> and firebug shows a syntax error.

I tried it again taking oub the ""

<select name="category" onchange="showSubcategory(document.getElementById(category).value)">

and then received the error message this document has not properties.


Michael Horowitz
Your Computer Consultant
http://yourcomputerconsultant.com
561-394-9079



Olly Hodgson wrote:
On Nov 14, 2007 10:37 PM, Michael Horowitz
<[EMAIL PROTECTED]> wrote:
I have examples using one value

onchange="showSubcategory(this.value)">

from a form to a script.

What if I need to send two values one from the current element in the
form and one from another element

onchange="showSubcategory(this.value,
document.getElementById("anotherElement").value);"




*******************************************************************
List Guidelines: http://webstandardsgroup.org/mail/guidelines.cfm
Unsubscribe: http://webstandardsgroup.org/join/unsubscribe.cfm
Help: [EMAIL PROTECTED]
*******************************************************************




*******************************************************************
List Guidelines: http://webstandardsgroup.org/mail/guidelines.cfm
Unsubscribe: http://webstandardsgroup.org/join/unsubscribe.cfm
Help: [EMAIL PROTECTED]
*******************************************************************

Reply via email to