3 # Display the contents of an autoreply file
5 require './qmail-lib.pl';
8 &ui_print_header(undef, $text{'rfile_title'}, "");
9 open(FILE, $in{'file'});
11 if (/^Reply-Tracking:\s*(.*)/) {
14 elsif (/^Reply-Period:\s*(.*)/) {
23 print "<b>",&text('rfile_desc', "<tt>$in{'file'}</tt>"),"</b><p>\n";
24 print "$text{'rfile_desc2'}<p>\n";
26 print "<form action=save_rfile.cgi method=post enctype=multipart/form-data>\n";
27 print "<input type=hidden name=file value=\"$in{'file'}\">\n";
28 print "<input type=hidden name=name value=\"$in{'name'}\">\n";
29 print "<textarea name=text rows=20 cols=80 $config{'wrap_mode'}>",
30 join("", @lines),"</textarea><p>\n";
32 print $text{'rfile_replies'},"\n";
33 printf "<input type=radio name=replies_def value=1 %s> %s\n",
34 $replies eq '' ? "checked" : "", $text{'rfile_none'};
35 printf "<input type=radio name=replies_def value=0 %s> %s\n",
36 $replies eq '' ? "" :"checked", $text{'rfile_file'};
37 printf "<input name=replies size=30 value='%s'> %s<br>\n",
38 $replies, &file_chooser_button("replies");
40 print $text{'rfile_period'},"\n";
41 printf "<input type=radio name=period_def value=1 %s> %s\n",
42 $period eq '' ? "checked" : "", $text{'rfile_default'};
43 printf "<input type=radio name=period_def value=0 %s>\n",
44 $period eq '' ? "" :"checked";
45 printf "<input name=period size=5 value='%s'> %s<p>\n",
46 $period, $text{'rfile_secs'};
48 print "<input type=submit value=\"$text{'save'}\"> ",
49 "<input type=reset value=\"$text{'rfile_undo'}\">\n";
52 &ui_print_footer("edit_alias.cgi?name=$in{'name'}", $text{'aform_return'});