[sword-cvs] swordweb parallelstudy.jsp,1.3,1.4

sword@www.crosswire.org sword@www.crosswire.org
Wed, 11 Jun 2003 01:08:04 -0700


Update of /usr/local/cvsroot/swordweb
In directory www:/tmp/cvs-serv23735

Modified Files:
	parallelstudy.jsp 
Log Message:
Added a loop to allow adding multiple modules with a single hit.  Useful
when sending someone there for the first time with an URL to get 2 modules
in parallel.



Index: parallelstudy.jsp
===================================================================
RCS file: /usr/local/cvsroot/swordweb/parallelstudy.jsp,v
retrieving revision 1.3
retrieving revision 1.4
diff -C2 -d -r1.3 -r1.4
*** parallelstudy.jsp	23 May 2003 22:51:11 -0000	1.3
--- parallelstudy.jsp	11 Jun 2003 08:08:02 -0000	1.4
***************
*** 2,11 ****
  
  <%
! 	String addModule = (String)request.getParameter("add");
! 	if (addModule != null) {
! 		SWModule m = mgr.getModuleByName( addModule );
! 		if (m != null) {
! 			parDispModules.remove(addModule);
! 			parDispModules.add(parDispModules.size(),addModule);
  		}
  	}
--- 2,16 ----
  
  <%
! 	String []addMods = request.getParameterValues("add");
! 	if (addMods != null) {
! 		for (int i = 0; i < addMods.length; i++) {
! 			String addModule = addMods[i];
! 			if (addModule != null) {
! 				SWModule m = mgr.getModuleByName(addModule);
! 				if (m != null) {
! 					parDispModules.remove(addModule);
! 					parDispModules.add(parDispModules.size(), addModule);
! 				}
! 			}
  		}
  	}