Skip to content
Snippets Groups Projects
Commit beef2e62 authored by rswindell's avatar rswindell
Browse files

Support extended/short file description toggle for Guest/Anonymous ftp-html.js

clients (using new ftp.extended_descriptions property).
parent 88955481
No related branches found
No related tags found
No related merge requests found
......@@ -277,7 +277,7 @@ if(ftp.file_list.length) {
if (ftp.curdir.name==undefined)
show_ext_desc=false; /* aliased files have no ext desc */
else
show_ext_desc=user.settings&USER_EXTDESC;
show_ext_desc=ftp.extended_descriptions;
writeln("<table " + cell_spacing + " width=100%>");
writeln(font_face);
......@@ -303,14 +303,12 @@ if(ftp.file_list.length) {
/* Description */
write("<th>" + hdr_font + "Description");
if(!(user.security.restrictions&UFLAG_G) && ftp.curdir.settings!=undefined) {
if(user.settings&USER_EXTDESC)
writeln(format(" [%s]"
,(hdr_font+"short").link(format("%s?ext=off$%s",html_index_file, time_stamp))));
else
writeln(format(" [%s]"
,(hdr_font+"extended").link(format("%s?ext=on$%s",html_index_file, time_stamp))));
}
if(ftp.extended_descriptions)
writeln(format(" [%s]"
,(hdr_font+"short").link(format("%s?ext=off$%s",html_index_file, time_stamp))));
else
writeln(format(" [%s]"
,(hdr_font+"extended").link(format("%s?ext=on$%s",html_index_file, time_stamp))));
/* Date/Time */
writeln(format("<th><a href=%s?sort=time%s$%s>%sDate/Time</a>"
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment