function setReqcode(id,methodName){
if(document.getElementById('approve').value==id)
{
alert("inside approve"+methodName);
action="ProcessPath.do?reqCode=approveVersion";
}
if(document.getElementById('reject').value==id)
{
alert("inside reject"+methodName);
action="ProcessPath.do?reqCode=rejectVersion"
}
}
i have to change the html:form action attribute according to if c开发者_开发知识库ondition. so please suggest some solution with example.
formReference.setAttribute('action', 'blah')
or
formRef.action='foo'
should suffice.
精彩评论