2 title=><?_ml .title _ml?>
11 LJ::set_active_crumb('export');
13 my $remote = LJ::get_remote();
14 return "<?needlogin?>"
18 my $authas = $GET{'authas'} || $remote->{'user'};
20 # no authentication needs to be done on this page, it's just a form anyway
23 $ret .= "<form action='export.bml' method='get'>\n";
24 $ret .= LJ::make_authas_select($remote, { 'authas' => $GET{'authas'}, 'showall' => 1 });
25 $ret .= "</form>\n\n";
27 $ret .= "<?h1 <?_ml .title _ml?> h1?>\n";
28 $ret .= "<?p <?_ml .description _ml?> p?>\n";
30 $ret .= "<form action='export_do.bml?authas=$authas' method='post'>\n";
33 $ret .= <<'HTMLBLOCK';
37 <tr valign='top'><td><?_ml .label.what _ml?></td>
39 <select name="what" id="what">
40 <option value="journal"><?_ml .what.entries _ml?></option>
45 <tr valign='middle'><td><?_ml .label.month _ml?></td>
47 <?_ml .label.month.year _ml?> <input name="year" size='4' maxlength='4' /> -
48 <?_ml .label.month.month _ml?> <input name="month" size='2' maxlength='2' />
51 <tr valign='top'><td><?_ml .label.format _ml?></td>
53 <select name="format">
54 <option value="csv"><?_ml .format.csv _ml?></option>
55 <option value="xml"><?_ml .format.xml _ml?></option>
57 <input type='checkbox' name="header" id="header" checked='checked' /> <label for="header"><?_ml .label.header _ml?></label><br />
58 <?_ml .label.encoding _ml?>
61 # unicode encoding selection
63 my (%encodings, %encnames);
64 LJ::load_codes({ "encoding" => \%encodings } );
65 LJ::load_codes({ "encname" => \%encnames } );
67 foreach my $id (keys %encodings) {
68 $selected = $id if lc($encodings{$id}) eq 'utf-8';
69 delete $encnames{$id} if lc($encodings{$id}) eq 'none';
71 $ret .= LJ::html_select({'name'=>'encid', 'selected'=>$selected},
72 map { $_, $encnames{$_} } sort keys %encnames);
74 $ret .= "<input type='text' name='encoding' size='15' maxlength='15' value='iso-8859-1' />";
78 $ret .= <<'HTMLBLOCK';
80 <input type='checkbox' name="notranslation" id="notranslation" /> <label for="notranslation"><?_ml .label.notranslation _ml?></label><br />
83 <tr><td colspan='2'><hr /></td></tr>
84 <tr valign='top'><td><?_ml .fields _ml?></td>
86 <input type='checkbox' name="field_itemid" id="field_itemid" checked='checked' /> <label for="field_itemid"><?_ml .label.field.itemid _ml?></label><br />
87 <input type='checkbox' name="field_eventtime" id="field_eventtime" checked='checked' /> <label for="field_eventtime"><?_ml .label.field.eventtime _ml?></label><br />
88 <input type='checkbox' name="field_logtime" id="field_logtime" checked='checked' /> <label for="field_logtime"><?_ml .label.field.logtime _ml?></label><br />
89 <input type='checkbox' name="field_subject" id="field_subject" checked='checked' /> <label for="field_subject"><?_ml .label.field.subject _ml?></label><br />
90 <input type='checkbox' name="field_event" id="field_event" checked='checked' /> <label for="field_event"><?_ml .label.field.event _ml?></label><br />
91 <input type='checkbox' name="field_security" id="field_security" checked='checked' /> <label for="field_security"><?_ml .label.field.security _ml?></label><br />
92 <input type='checkbox' name="field_allowmask" id="field_allowmask" checked='checked' /> <label for="field_allowmask"><?_ml .label.field.allowmask _ml?></label><br />
93 <input type='checkbox' name='field_currents' id="field_currents" checked='checked' /> <label for="field_currents"><?_ml .label.field.currents _ml?></label><br />
96 <tr><td></td><td><input type="submit" value="<?_ml .btn.proceed _ml?>" /></td></tr>
101 <?h1 <?_ml lostinfo.head _ml?> h1?>
104 $ret .= "<?p " . BML::ml('lostinfo.text2', {'aopts' => "href='$LJ::SITEROOT/lostinfo.bml'"}) . " p?>";
110 post: htdocs/export_do.bml