| … | |
… | |
| 45 | my $courseDirectory = $Global::coursesDirectory . $Course . $Global::dirDelim; |
45 | my $courseDirectory = $Global::coursesDirectory . $Course . $Global::dirDelim; |
| 46 | my $courseScriptsDirectory = getCourseScriptsDirectory; |
46 | my $courseScriptsDirectory = getCourseScriptsDirectory; |
| 47 | my $databaseDirectory = getCourseDatabaseDirectory; |
47 | my $databaseDirectory = getCourseDatabaseDirectory; |
| 48 | my $htmlURL = getCourseHtmlURL; |
48 | my $htmlURL = getCourseHtmlURL; |
| 49 | my $scriptDirectory = getWebworkScriptDirectory; |
49 | my $scriptDirectory = getWebworkScriptDirectory; |
|
|
50 | my $htmlDirectory = getCourseHtmlDirectory; |
| 50 | my $templateDirectory = getCourseTemplateDirectory; |
51 | my $templateDirectory = getCourseTemplateDirectory; |
| 51 | my $dat = getDat; |
52 | my $dat = getDat; |
| 52 | |
53 | |
| 53 | require "${scriptDirectory}$Global::DBglue_pl"; |
54 | require "${scriptDirectory}$Global::DBglue_pl"; |
| 54 | require "${scriptDirectory}$Global::FILE_pl"; |
55 | require "${scriptDirectory}$Global::FILE_pl"; |
| … | |
… | |
| 138 | hiddens('user', 'key', 'course'), |
139 | hiddens('user', 'key', 'course'), |
| 139 | $cgi->hidden(-name=>'filename', -value=>$Global::courseEnvironmentFile), "\n", |
140 | $cgi->hidden(-name=>'filename', -value=>$Global::courseEnvironmentFile), "\n", |
| 140 | $cgi->hidden(-name=>'ext', -value=>'ph'), "\n", |
141 | $cgi->hidden(-name=>'ext', -value=>'ph'), "\n", |
| 141 | $cgi->endform(), "\n", |
142 | $cgi->endform(), "\n", |
| 142 | $cgi->p, "This lets you edit the Course Environment File for $Course."; |
143 | $cgi->p, "This lets you edit the Course Environment File for $Course."; |
|
|
144 | |
|
|
145 | |
|
|
146 | # html/index.html |
|
|
147 | $filename = "${htmlDirectory}index.html"; |
|
|
148 | #($date, $label, @stat); |
|
|
149 | if (-e $filename) { |
|
|
150 | @stat = stat($filename); |
|
|
151 | $date = $stat[9]; |
|
|
152 | $date = formatDateAndTime($date); |
|
|
153 | $date =~ s|\s*at.*||; |
|
|
154 | $label = " Last Changed $date"; |
|
|
155 | } |
|
|
156 | |
|
|
157 | print heading('Index', "5. Edit Course index.html File for $Course:"), |
|
|
158 | $cgi->startform(-action=>"${cgiURL}profEditCourseFiles.pl"), |
|
|
159 | $cgi->submit(-value=>'Edit Course index.html File'), "$label\n", |
|
|
160 | hiddens('user', 'key', 'course'), |
|
|
161 | $cgi->hidden(-name=>'filename', -value=>"index.html"), "\n", |
|
|
162 | $cgi->hidden(-name=>'ext', -value=>'html'), "\n", |
|
|
163 | $cgi->endform(), "\n", |
|
|
164 | $cgi->p, "This lets you edit the Course index.html File for $Course."; |
| 143 | |
165 | |
| 144 | |
166 | |
| 145 | print &htmlBOTTOM("profHousekeeping.pl", \%inputs); |
167 | print &htmlBOTTOM("profHousekeeping.pl", \%inputs); |
| 146 | |
168 | |
| 147 | # begin Timing code |
169 | # begin Timing code |