3 # Display printing options
5 require './samba-lib.pl';
9 &error_setup("<blink><font color=red>$text{'eacl_aviol'}</font></blink>");
10 &error("$text{'eacl_np'} $text{'eacl_pcprint'}") unless $access{'conf_print'};
12 &ui_print_header(undef, $text{'print_title'}, "");
16 print "<form action=save_print.cgi>\n";
17 print "<table border width=100%>\n";
18 print "<tr $tb> <td><b>$text{'print_title'}</b></td> </tr>\n";
19 print "<tr $cb> <td><table width=100%>\n";
21 print "<tr> <td><b>$text{'print_style'}</b></td>\n";
22 print "<td><select name=printing>\n";
23 printf "<option value=\"\" %s> $text{'default'}\n",
24 &getval("printing") eq "" ? "selected" : "";
25 foreach $s ("bsd", "sysv", "hpux", "aix", "qnx", "plp", "cups", "lprng",
27 printf "<option value=$s %s> %s\n",
28 &getval("printing") eq $s ? "selected" : "", uc($s);
30 print "</select></td>\n";
32 print "<td><b>$text{'print_show'}</b></td>\n";
33 printf "<td><input type=radio name=load_printers value=yes %s> $text{'yes'}\n",
34 &istrue("load printers") ? "checked" : "";
35 printf "<input type=radio name=load_printers value=no %s> $text{'no'}</td></tr>\n",
36 &istrue("load printers") ? "" : "checked";
38 print "<tr> <td><b>$text{'print_printcap'}</b></td>\n";
39 print "<td colspan=3>\n";
40 printf "<input type=radio name=printcap_name_def value=1 %s> $text{'default'}\n",
41 &getval("printcap name") eq "" ? "checked" : "";
42 printf " <input type=radio name=printcap_name_def value=0 %s>\n",
43 &getval("printcap name") eq "" ? "" : "checked";
44 printf "<input name=printcap_name size=25 value=\"%s\">\n",
45 &getval("printcap name");
46 print &file_chooser_button("printcap_name", 0);
47 print "</td> </tr>\n";
49 print "<tr> <td><b>$text{'print_cachetime'}</b></td>\n";
50 print "<td colspan=3>\n";
51 printf "<input type=radio name=lpq_cache_time_def value=1 %s> $text{'default'}\n",
52 &getval("lpq cache time") == 0 ? "checked" : "";
53 printf " <input type=radio name=lpq_cache_time_def value=0 %s>\n",
54 &getval("lpq cache time") == 0 ? "" : "checked";
55 printf "<input name=lpq_cache_time size=5 value=\"%s\"> $text{'config_secs'}</td> </tr>\n",
56 &getval("lpq cache time");
58 print "</table></td></tr></table><p>\n";
59 print "<input type=submit value=$text{'save'}></form>\n";
61 &ui_print_footer("", $text{'index_sharelist'});