[LON-CAPA-cvs] cvs: loncom /interface loncreateuser.pm
albertel
lon-capa-cvs-allow@mail.lon-capa.org
Fri, 20 Jul 2007 23:55:14 -0000
albertel Fri Jul 20 19:55:14 2007 EDT
Modified files:
/loncom/interface loncreateuser.pm
Log:
- was breaking on domain/courses iwith . or - in name
Index: loncom/interface/loncreateuser.pm
diff -u loncom/interface/loncreateuser.pm:1.157 loncom/interface/loncreateuser.pm:1.158
--- loncom/interface/loncreateuser.pm:1.157 Fri Jul 20 19:52:55 2007
+++ loncom/interface/loncreateuser.pm Fri Jul 20 19:55:12 2007
@@ -1,7 +1,7 @@
# The LearningOnline Network with CAPA
# Create a user
#
-# $Id: loncreateuser.pm,v 1.157 2007/07/20 23:52:55 albertel Exp $
+# $Id: loncreateuser.pm,v 1.158 2007/07/20 23:55:12 albertel Exp $
#
# Copyright Michigan State University Board of Trustees
#
@@ -65,7 +65,6 @@
use Apache::loncommon;
use Apache::lonlocal;
use Apache::longroup;
-use lib '/home/httpd/lib/perl/';
use LONCAPA qw(:DEFAULT :match);
my $loginscript; # piece of javascript used in two separate instances
@@ -429,9 +428,8 @@
var checkcurr = str.match(re1);
if (checkcurr != null) {
if (document.cu.elements[i-1].checked == true) {
- var re2 = /^currsec_[a-zA-Z0-9]+_[a-zA-Z0-9]+_(\\w+)\$/;
- match = re2.exec(str);
- var role = match[1];
+ var match = str.split('_');
+ var role = match[3];
if (role == 'cc') {
alert("Section designations do not apply to Course Coordinator roles.\\nA course coordinator role will be added with access to all sections.");
}