I have a event type and event organizer.Based on the event type,event organizer will search.All the functions are working properly ,but name is not printing on the screen.Here is the code.
<tr>
<td class="bg1" width="25%">Event Organizer User Type </td>
<td class="bg1" width="25%"><edu:select name="usertype" fieldlist="<%=userType%>" selvalue='STUDENT' noselect="true" onclick="TypeValue(this)"/> </td>
<td class="bg1" width="25%"><div id="ele">Student Id<edu:prnStar /><a href=# onClick='openwindow2()'><img src='../images/util/final.gif' name='search' width='20' height='20' alt='Search' border='0'></a></div></td>
<td class="bg1" width="25%"> <input type="text" name="eventorganizer" id="eventorganizer" maxlength="25" onblur="validateField('SPLALPHA',this)"/> </td-->
</tr>
Here are the functions
function TypeValue(as){
ttype=as.value;
if(ttype=="STUDENT"){
document.getElementById('ele').innerHTML="Student Id<edu:prnStar/><a href=# onClick='openwindow2()'><img src='../images/util/final.gif' name='search' width='20' height='20' alt='Search' border='0'></a>";
}else if(ttype=="STAFF"){
document.getElementById('ele').innerHTML="Staff Id<edu:prnStar/><a href=# onClick='openwindow1()'><img src='../images/util/final.gif' name='search' width='20' height='20' alt='Search' border='0'></a>";
}else{
document.getElementById('ele').innerHTML="Guest/Visitor Id<edu:prnStar/><a href=# onClick='openwindow3()'><img src='../images/util/final.gif' name='search' width='20' height='20' alt='Search' border='0'></a>";
}
document.edufrm.typee.value=ttype;
}
//For Dynamic Staff Search
function openwindow1()
{
window.open('EduManage.jsp?control=search1&searchno=5_0s1&position=2','','width=790,height=420,left=0,top=70,scrollbars=1,location=no,status=no,resizable=yes');
}
//For Dynamic Student Search
function openwindow2()
{
window.open('EduManage.jsp?control=search1&searchno=3_0s1&position=2','','width=790,height=420,left=0,top=70,scrollbars=1,location=no,status=no,resizable=yes');
}
Can anyone help?