version 1.5, 2003/03/27 02:05:43
|
version 1.8, 2003/09/22 00:48:32
|
Line 33 use Apache::Constants qw(:common);
|
Line 33 use Apache::Constants qw(:common);
|
use Apache::loncommon; |
use Apache::loncommon; |
use Apache::loncoursedata; |
use Apache::loncoursedata; |
use Apache::lonnet; |
use Apache::lonnet; |
|
use Apache::lonlocal; |
|
|
sub handler { |
sub handler { |
my $r = shift; |
my $r = shift; |
$r->content_type('text/html'); |
&Apache::loncommon::content_type($r,'text/html'); |
$r->send_http_header; |
$r->send_http_header; |
return OK if $r->header_only; |
return OK if $r->header_only; |
|
|
Line 76 ENDDOCUMENT
|
Line 77 ENDDOCUMENT
|
'31104000' => 'last year')); |
'31104000' => 'last year')); |
|
|
$r->print(&Apache::loncommon::bodytag("Selecting a Course")); |
$r->print(&Apache::loncommon::bodytag("Selecting a Course")); |
|
my %lt=&Apache::lonlocal::texthash( |
|
'cac' => 'Course Activity', |
|
'cde' => 'Course Description', |
|
'cdo' => 'Course Domain'); |
$r->print(<<ENDSCRIPT); |
$r->print(<<ENDSCRIPT); |
<script> |
<script> |
function gochoose(cname,cdom) { |
function gochoose(cname,cdom) { |
Line 83 function gochoose(cname,cdom) {
|
Line 88 function gochoose(cname,cdom) {
|
var slct=opener.document.$ENV{'form.form'}.$ENV{'form.cdomelement'}; |
var slct=opener.document.$ENV{'form.form'}.$ENV{'form.cdomelement'}; |
var i; |
var i; |
for (i=0;i<slct.length;i++) { |
for (i=0;i<slct.length;i++) { |
if (slct[i]==cdom) { slct.selectedIndex=i; } |
if (slct.options[i].value==cdom) { slct.selectedIndex=i; } |
} |
} |
self.close(); |
self.close(); |
} |
} |
Line 93 function gochoose(cname,cdom) {
|
Line 98 function gochoose(cname,cdom) {
|
<input type="hidden" name="cdomelement" value="$ENV{'form.cdomelement'}" /> |
<input type="hidden" name="cdomelement" value="$ENV{'form.cdomelement'}" /> |
<input type="hidden" name="form" value="$ENV{'form.form'}" /> |
<input type="hidden" name="form" value="$ENV{'form.form'}" /> |
|
|
Course Activity: $sincefilterform |
$lt{'cac'}: $sincefilterform |
<br /> |
<br /> |
Course Domain: $domainselectform |
$lt{'cdo'}: $domainselectform |
<br /> |
<br /> |
Course Description: |
$lt{'cde'}: |
<input type="text" name="descriptfilter" size="40" value="$descriptfilter" /> |
<input type="text" name="descriptfilter" size="40" value="$descriptfilter" /> |
<p><input type="submit" name="gosearch" value="Search" /></p> |
<p><input type="submit" name="gosearch" value="Search" /></p> |
</form> |
</form> |
<hr /> |
<hr /> |
ENDSCRIPT |
ENDSCRIPT |
$r->rflush(); |
|
# ---------------------------------------------------------------- Get the data |
# ---------------------------------------------------------------- Get the data |
if ($ENV{'form.gosearch'}) { |
if ($ENV{'form.gosearch'}) { |
|
$r->print(&mt('Searching').' ...<br /> <br />'); |
|
$r->rflush(); |
unless ($descriptfilter) { $descriptfilter='.'; } |
unless ($descriptfilter) { $descriptfilter='.'; } |
my $timefilter=($sincefilter==-1?1:time-$sincefilter); |
my $timefilter=($sincefilter==-1?1:time-$sincefilter); |
my %courses= |
my %courses= |