- In EnterRoomAction.execute(), in the "else" block of
if("enter".equals(action)),
the code takes parameter values from the 'request' and copies
them into the EnterRoomForm. We've added:
erForm.setEmail(request.getParameter("email"));
erForm.setParticipantName(request.getParameter("participantName"));
This makes it possible for the "j.do" URL (from which a user can
join a meeting) to pass along the user's email address (aka their
WebHuddle userid) and their full name, without having to actually
type those values into form fields.
(It should be possible to add these two lines to the master WebHuddle
code w/o compromising or changing its function; but that, of course,
is up to the primary WebHuddle developer(s).)
- In wmTemplate.jsp, we've added the ability to call a custom
Javascript "onLoad" function.
Right after the <html:base/> tag, we've added:
<script language="javascript">
function callMyOnLoadIfExists() {
if (window.myOnLoad) myOnLoad();
}
</script>
And changed the <body> tag to include
onLoad="callMyOnLoadIfExists();".
This means that any JSP page that includes wmTemplate.jsp may have
its own definition of "myOnLoad()", which will then be called when
the page finishes loading.
(This code could similarly be added to the master WebHuddle distribution.)
- Finally, we've changed enterroom.jsp to take advantage of #1 and #2,
and simply made it submit itself as soon as it is loaded.
So right before the <html:form> tag, we've added:
<script language="javascript">
function myOnLoad() {
document.enterRoomForm.submit();
}
</script>
(This is an incompatible change, but it could easily be cleaned up by, say,
adding another querystring parameter to j.do, say "autosubmit=1",
passing it through EnterRoomAction to the EnterRoomForm, and then
having myOnLoad() check it.)