Hi,
I have a script that is meant to change the value of a hidden field and then change the css of form in which the hidden field is in to visible.
The css change works but the change value does not. Can any one help?
The java code:
You click this link to run the program:Code:<script language="javascript"> function ChangeHiddenValue() { var MyElement = document.getElementById("target_url"); MyElement.value = "If you see this, it worked!"; document.getElementById('sign_in_light').style.display='block';document.getElementById('fade').style.display='block'; } //--> </script>
And the form:HTML Code:<a href = \"javascript:void(0)\" onclick = \"javascript:ChangeHiddenValue(this.value);\">Africa</a>
All help is appreciated.HTML Code:<form action="xxxx.php" method="post" enctype="multipart/form-data" name="sign_in_light" id="sign_in_light" onsubmit="return rsv.validate(this, sign_in_rules)"> <div class="signinpatchformline"><span class="signinpatchformlinetext">Email:</span><input name="email" id="email"/> <input type="hidden" name="target_url" id="target_url" value="" /> </div> <div class="signinpatchformline"><span class="signinpatchformlinetext">Password:</span><input name="password" type="password" id="password"/> </div> <div class="signinpatchbutton"><span class="signinpatchformlineforgot">Forgot your password?</span> <div class="buttonsright"><button type="submit" class="darkblue">Sign in</button></div></div> </form>
Cs1h



Reply With Quote

Bookmarks