version 1.14, 2007/11/13 01:14:11
|
version 1.15, 2007/11/13 01:47:56
|
Line 92 sub code_list {
|
Line 92 sub code_list {
|
# $context = 1 No page header, print enclosing table |
# $context = 1 No page header, print enclosing table |
# $context = 2 No page header, no enclosing table |
# $context = 2 No page header, no enclosing table |
my $table_head; |
my $table_head; |
my $enc_table_start; |
my $extra_css; |
my $enc_table_close; |
|
|
|
if (!$context) { |
if (!$context) { |
$r->print(&Apache::loncommon::start_page("View CODEs",undef, |
$r->print(&Apache::loncommon::start_page("View CODEs",undef, |
{'no_nav_bar' => 1})); |
{'no_nav_bar' => 1})); |
$table_head = ('<b>'.&mt('Select a set of saved CODEs to view.')."</b>"); |
$table_head = &mt('Select a set of saved CODEs to view.'); |
} elsif ($context eq 1) { |
} elsif ($context eq 1) { |
$table_head = ('<b>'.&mt('Select another set of saved CODEs to view.')."</b>"); |
$table_head = &mt('Select another set of saved CODEs to view.'); |
$enc_table_start = '<table width="100%"><tr><td bgcolor="#777777">'; |
|
$enc_table_close = '</tr></td></table>'; |
|
} elsif ($context eq 2) { |
} elsif ($context eq 2) { |
$table_head = ('<b>'.&mt('Select a set of saved CODEs to view.')."</b>"); |
$table_head = &mt('Select a set of saved CODEs to view.'); |
|
$extra_css = 'LC_scantron_action'; |
} |
} |
$r->print("<form method='post' action='/adm/pickcode' name='pickcode'>"); |
$r->print("<form method='post' action='/adm/pickcode' name='pickcode'>"); |
$r->print($enc_table_start); |
$r->print(' |
$r->print('<table width="100%">'); |
'.&Apache::loncommon::start_data_table($extra_css).' |
$r->print('<tr><td bgcolor="#e6ffff">'); |
'.&Apache::loncommon::start_data_table_header_row()); |
|
$r->print('<th>'); |
$r->print($table_head); |
$r->print($table_head); |
$r->print('</td></tr>'); |
$r->print('</th>'); |
$r->print('<tr><td bgcolor="#ffffe6">'); |
$r->print(' |
|
'.&Apache::loncommon::end_data_table_header_row().' |
|
'.&Apache::loncommon::start_data_table_row()); |
|
$r->print('<td>'); |
$r->print("<input type='submit' name='submit' value='".&mt("View:")."' /> "); |
$r->print("<input type='submit' name='submit' value='".&mt("View:")."' /> "); |
$r->print(&Apache::grades::scantron_CODElist()); |
$r->print(&Apache::grades::scantron_CODElist()); |
$r->print('</td></tr>'); |
$r->print('</td>'); |
$r->print('</table>'); |
$r->print(' |
$r->print($enc_table_close); # conditional |
'.&Apache::loncommon::end_data_table_row().' |
|
'.&Apache::loncommon::end_data_table()); |
$r->print("<input type='hidden' name='command' value='showcodes' />"); |
$r->print("<input type='hidden' name='command' value='showcodes' />"); |
$r->print("<input type='hidden' name='symb' value='".$env{'form.symb'}."' />"); |
$r->print("<input type='hidden' name='symb' value='".$env{'form.symb'}."' />"); |
$r->print("<input type='hidden' name='url' value='".$env{'form.url'}."' />"); |
$r->print("<input type='hidden' name='url' value='".$env{'form.url'}."' />"); |