-
-
-
-
-
-
-
-
-"
-
-footer
-
diff --git a/var/mongoose/cgi-bin/edit/get.jim b/var/mongoose/cgi-bin/edit/get.jim
deleted file mode 100755
index 735044b..0000000
--- a/var/mongoose/cgi-bin/edit/get.jim
+++ /dev/null
@@ -1,24 +0,0 @@
-#!/mod/bin/jimsh
-
-package require cgi
-source /mod/var/mongoose/lib/setup
-require chunked
-
-cgi_input
-#cgi_dump
-
-set file [cgi_get file "/tmp/hosts"]
-if {$file eq "-"} { exit }
-
-start_chunked
-
-if {![file exists $file]} {
- chunk ">>> File $file does not exist.\r\n"
-} else {
- set fp [open $file r]
- chunk [read $fp]
- close $fp
-}
-
-end_chunked
-
diff --git a/var/mongoose/cgi-bin/edit/script.js b/var/mongoose/cgi-bin/edit/script.js
deleted file mode 100644
index d33f9a4..0000000
--- a/var/mongoose/cgi-bin/edit/script.js
+++ /dev/null
@@ -1,51 +0,0 @@
-
-$(function() {
-
-var file = $('#filename').text();
-
-function loadfile()
-{
- $('button.afterload').disable();
- $('#editor')
- .addClass('loading')
- .val('Loading file...');
- $.get('get.jim?file=' + encodeURIComponent(file), function(data) {
- $('#editor')
- .removeClass('loading')
- .val(data);
- $('button.afterload').enable();
- });
-}
-
-$('#save')
- .button()
- .click(function() {
- $.post('put.jim', {
- 'file': file,
- 'data': $('#editor').val()
- }, function(data) {
- $('#result')
- .html(data)
- .slideDown('slow')
- .delay(5000)
- .slideUp('slow');
- });
- });
-
-$('#revert')
- .button()
- .click(function() {
- loadfile();
- });
-
-$('#back')
- .button()
- .click(function() {
- window.location = '/diag.shtml';
- });
-
-$('#editor').tabsupport();
-loadfile();
-
-});
-
diff --git a/var/mongoose/cgi-bin/settings.jim b/var/mongoose/cgi-bin/settings.jim
index 588f8eb..6804d29 100755
--- a/var/mongoose/cgi-bin/settings.jim
+++ b/var/mongoose/cgi-bin/settings.jim
@@ -335,24 +335,5 @@ puts ">
eval_plugins settings
-#puts {
-#
-#
-#
-#
-#}
-
footer
diff --git a/var/mongoose/html/css/jqueryFileTree.css b/var/mongoose/html/css/jqueryFileTree.css
new file mode 100644
index 0000000..6ecab06
--- /dev/null
+++ b/var/mongoose/html/css/jqueryFileTree.css
@@ -0,0 +1,91 @@
+UL.jqueryFileTree {
+ font-family: Verdana, sans-serif;
+ font-size: 11px;
+ line-height: 18px;
+ padding: 0px;
+ margin: 0px;
+}
+
+UL.jqueryFileTree LI {
+ list-style: none;
+ padding: 0px;
+ padding-left: 20px;
+ margin: 0px;
+ white-space: nowrap;
+}
+
+UL.jqueryFileTree A {
+ color: #333;
+ text-decoration: none;
+ display: block;
+ padding: 0px 2px;
+}
+
+UL.jqueryFileTree A:hover {
+ background: #BDF;
+}
+
+/* Core Styles */
+.jqueryFileTree LI.directory { background: url(/img/filetree/directory.png) left top no-repeat; }
+.jqueryFileTree LI.expanded { background: url(/img/filetree/folder_open.png) left top no-repeat; }
+.jqueryFileTree LI.file { background: url(/img/filetree/file.png) left top no-repeat; }
+.jqueryFileTree LI.wait { background: url(/img/filetree/spinner.gif) left top no-repeat; }
+/* File Extensions*/
+.jqueryFileTree LI.ext_3gp { background: url(/img/filetree/film.png) left top no-repeat; }
+.jqueryFileTree LI.ext_afp { background: url(/img/filetree/code.png) left top no-repeat; }
+.jqueryFileTree LI.ext_afpa { background: url(/img/filetree/code.png) left top no-repeat; }
+.jqueryFileTree LI.ext_asp { background: url(/img/filetree/code.png) left top no-repeat; }
+.jqueryFileTree LI.ext_aspx { background: url(/img/filetree/code.png) left top no-repeat; }
+.jqueryFileTree LI.ext_avi { background: url(/img/filetree/film.png) left top no-repeat; }
+.jqueryFileTree LI.ext_bat { background: url(/img/filetree/application.png) left top no-repeat; }
+.jqueryFileTree LI.ext_bmp { background: url(/img/filetree/picture.png) left top no-repeat; }
+.jqueryFileTree LI.ext_c { background: url(/img/filetree/code.png) left top no-repeat; }
+.jqueryFileTree LI.ext_cfm { background: url(/img/filetree/code.png) left top no-repeat; }
+.jqueryFileTree LI.ext_cgi { background: url(/img/filetree/code.png) left top no-repeat; }
+.jqueryFileTree LI.ext_com { background: url(/img/filetree/application.png) left top no-repeat; }
+.jqueryFileTree LI.ext_cpp { background: url(/img/filetree/code.png) left top no-repeat; }
+.jqueryFileTree LI.ext_css { background: url(/img/filetree/css.png) left top no-repeat; }
+.jqueryFileTree LI.ext_doc { background: url(/img/filetree/doc.png) left top no-repeat; }
+.jqueryFileTree LI.ext_exe { background: url(/img/filetree/application.png) left top no-repeat; }
+.jqueryFileTree LI.ext_gif { background: url(/img/filetree/picture.png) left top no-repeat; }
+.jqueryFileTree LI.ext_fla { background: url(/img/filetree/flash.png) left top no-repeat; }
+.jqueryFileTree LI.ext_h { background: url(/img/filetree/code.png) left top no-repeat; }
+.jqueryFileTree LI.ext_htm { background: url(/img/filetree/html.png) left top no-repeat; }
+.jqueryFileTree LI.ext_html { background: url(/img/filetree/html.png) left top no-repeat; }
+.jqueryFileTree LI.ext_jar { background: url(/img/filetree/java.png) left top no-repeat; }
+.jqueryFileTree LI.ext_jpg { background: url(/img/filetree/picture.png) left top no-repeat; }
+.jqueryFileTree LI.ext_jpeg { background: url(/img/filetree/picture.png) left top no-repeat; }
+.jqueryFileTree LI.ext_js { background: url(/img/filetree/script.png) left top no-repeat; }
+.jqueryFileTree LI.ext_lasso { background: url(/img/filetree/code.png) left top no-repeat; }
+.jqueryFileTree LI.ext_log { background: url(/img/filetree/txt.png) left top no-repeat; }
+.jqueryFileTree LI.ext_m4p { background: url(/img/filetree/music.png) left top no-repeat; }
+.jqueryFileTree LI.ext_mov { background: url(/img/filetree/film.png) left top no-repeat; }
+.jqueryFileTree LI.ext_mp3 { background: url(/img/filetree/music.png) left top no-repeat; }
+.jqueryFileTree LI.ext_mp4 { background: url(/img/filetree/film.png) left top no-repeat; }
+.jqueryFileTree LI.ext_mpg { background: url(/img/filetree/film.png) left top no-repeat; }
+.jqueryFileTree LI.ext_mpeg { background: url(/img/filetree/film.png) left top no-repeat; }
+.jqueryFileTree LI.ext_ogg { background: url(/img/filetree/music.png) left top no-repeat; }
+.jqueryFileTree LI.ext_pcx { background: url(/img/filetree/picture.png) left top no-repeat; }
+.jqueryFileTree LI.ext_pdf { background: url(/img/filetree/pdf.png) left top no-repeat; }
+.jqueryFileTree LI.ext_php { background: url(/img/filetree/php.png) left top no-repeat; }
+.jqueryFileTree LI.ext_png { background: url(/img/filetree/picture.png) left top no-repeat; }
+.jqueryFileTree LI.ext_ppt { background: url(/img/filetree/ppt.png) left top no-repeat; }
+.jqueryFileTree LI.ext_psd { background: url(/img/filetree/psd.png) left top no-repeat; }
+.jqueryFileTree LI.ext_pl { background: url(/img/filetree/script.png) left top no-repeat; }
+.jqueryFileTree LI.ext_py { background: url(/img/filetree/script.png) left top no-repeat; }
+.jqueryFileTree LI.ext_rb { background: url(/img/filetree/ruby.png) left top no-repeat; }
+.jqueryFileTree LI.ext_rbx { background: url(/img/filetree/ruby.png) left top no-repeat; }
+.jqueryFileTree LI.ext_rhtml { background: url(/img/filetree/ruby.png) left top no-repeat; }
+.jqueryFileTree LI.ext_rpm { background: url(/img/filetree/linux.png) left top no-repeat; }
+.jqueryFileTree LI.ext_ruby { background: url(/img/filetree/ruby.png) left top no-repeat; }
+.jqueryFileTree LI.ext_sql { background: url(/img/filetree/db.png) left top no-repeat; }
+.jqueryFileTree LI.ext_swf { background: url(/img/filetree/flash.png) left top no-repeat; }
+.jqueryFileTree LI.ext_tif { background: url(/img/filetree/picture.png) left top no-repeat; }
+.jqueryFileTree LI.ext_tiff { background: url(/img/filetree/picture.png) left top no-repeat; }
+.jqueryFileTree LI.ext_txt { background: url(/img/filetree/txt.png) left top no-repeat; }
+.jqueryFileTree LI.ext_vb { background: url(/img/filetree/code.png) left top no-repeat; }
+.jqueryFileTree LI.ext_wav { background: url(/img/filetree/music.png) left top no-repeat; }
+.jqueryFileTree LI.ext_wmv { background: url(/img/filetree/film.png) left top no-repeat; }
+.jqueryFileTree LI.ext_xls { background: url(/img/filetree/xls.png) left top no-repeat; }
+.jqueryFileTree LI.ext_xml { background: url(/img/filetree/code.png) left top no-repeat; }
+.jqueryFileTree LI.ext_zip { background: url(/img/filetree/zip.png) left top no-repeat; }
diff --git a/var/mongoose/html/diag.shtml b/var/mongoose/html/diag.shtml
deleted file mode 100644
index 919ccd7..0000000
--- a/var/mongoose/html/diag.shtml
+++ /dev/null
@@ -1,61 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/var/mongoose/html/diag/diag.jim b/var/mongoose/html/diag/diag.jim
new file mode 100755
index 0000000..2849544
--- /dev/null
+++ b/var/mongoose/html/diag/diag.jim
@@ -0,0 +1,80 @@
+#!/mod/bin/jimsh
+
+package require cgi
+source /mod/var/mongoose/lib/setup
+require pretty_size
+
+puts "Content-Type: text/html"
+puts ""
+
+header
+
+puts {
+
+
+
+
+
+
+
+
+
+}
+
+footer
+
diff --git a/var/mongoose/cgi-bin/diag.jim b/var/mongoose/html/diag/rundiag.jim
similarity index 100%
rename from var/mongoose/cgi-bin/diag.jim
rename to var/mongoose/html/diag/rundiag.jim
diff --git a/var/mongoose/html/diag/script.js b/var/mongoose/html/diag/script.js
new file mode 100644
index 0000000..6497f9d
--- /dev/null
+++ b/var/mongoose/html/diag/script.js
@@ -0,0 +1,45 @@
+
+$(function() {
+
+$('button').button();
+
+$('#rundiag').click(function() {
+ $('#results')
+ .slideDown()
+ .text('\n\nRunning diagnostic, please wait...\n\n')
+ .load('rundiag.jim?diag=' +
+ encodeURIComponent($('#seq').val()), function() {
+ $('#results').wrapInner('');
+ });
+});
+
+$('#runfopkg').click(function() {
+ $('#results')
+ .slideDown()
+ .text('\n\nForcibly re-installing package, please wait...\n\n')
+ .load('/cgi-bin/opkg.jim?cmd=install+--force-reinstall+' +
+ encodeURIComponent($('#fopkg').val()), function() {
+ $('#results').wrapInner('');
+ $('#fopkg').val('');
+ });
+});
+
+$('a.log').click(function() {
+ $('#results')
+ .slideDown()
+ .text('\n\nLoading log, please wait...\n\n')
+ .load('/cgi-bin/cat.jim?file=' +
+ encodeURIComponent($(this).attr('file')), function() {
+ $('#results').wrapInner('');
+ });
+});
+
+$('#runedit').click(function(e) {
+ e.preventDefault();
+ window.location = '/edit/edit.jim';
+});
+
+$('#runreset').disable();
+
+});
+
diff --git a/var/mongoose/html/edit/edit.jim b/var/mongoose/html/edit/edit.jim
new file mode 100755
index 0000000..c114334
--- /dev/null
+++ b/var/mongoose/html/edit/edit.jim
@@ -0,0 +1,53 @@
+#!/mod/bin/jimsh
+
+package require cgi
+source /mod/var/mongoose/lib/setup
+
+puts "Content-Type: text/html"
+puts ""
+
+header
+
+cgi_input
+#cgi_dump
+set file [cgi_get file "/tmp/hosts"]
+
+puts {
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+}
+
+footer
+
diff --git a/var/mongoose/html/edit/files.jim b/var/mongoose/html/edit/files.jim
new file mode 100755
index 0000000..f35d821
--- /dev/null
+++ b/var/mongoose/html/edit/files.jim
@@ -0,0 +1,43 @@
+#!/mod/bin/jimsh
+
+package require cgi
+source /mod/var/mongoose/lib/setup
+
+cgi_input
+#cgi_dump
+
+puts "Content-Type: text/html"
+puts ""
+
+set root [cgi_get dir]
+
+set files [lsort [readdir -nocomplain $root]]
+
+puts ""
+
+foreach dir $files {
+ set path "$root/$dir"
+ regsub -all -- {\/+} $path "/" path
+ if {![file isdirectory $path]} continue
+ puts -nonewline "- [cgi_quote_html $dir]
"
+}
+
+foreach file $files {
+ set path "$root/$file"
+ regsub -all -- {\/+} $path "/" path
+ if {[file isdirectory $path]} continue
+ set ext [file extension $file]
+ puts -nonewline "- "
+ puts -nonewline ""
+ puts -nonewline [cgi_quote_html $file]
+ puts "
"
+}
+
+puts "
"
+
diff --git a/var/mongoose/html/edit/get.jim b/var/mongoose/html/edit/get.jim
new file mode 100755
index 0000000..67d4b3a
--- /dev/null
+++ b/var/mongoose/html/edit/get.jim
@@ -0,0 +1,32 @@
+#!/mod/bin/jimsh
+
+package require cgi
+source /mod/var/mongoose/lib/setup
+require chunked pretty_size
+
+cgi_input
+#cgi_dump
+
+set file [cgi_get file "/tmp/hosts"]
+if {$file eq "-"} { exit }
+
+start_chunked
+
+if {![file exists $file]} {
+ chunk ">>> File $file does not exist.\r\n"
+} else {
+ set type [exec /mod/bin/file --brief --mime-type --dereference $file]
+ if {![string match {text/*} $type]} {
+ chunk ">>> File $file is not a plain file ($type)"
+ } elseif {[file size $file] > 102400} {
+ chunk ">>> File $file is too large."
+ chunk ">>> [pretty_size [file size $file]]"
+ } else {
+ set fp [open $file r]
+ chunk [read $fp]
+ close $fp
+ }
+}
+
+end_chunked
+
diff --git a/var/mongoose/cgi-bin/edit/put.jim b/var/mongoose/html/edit/put.jim
similarity index 100%
rename from var/mongoose/cgi-bin/edit/put.jim
rename to var/mongoose/html/edit/put.jim
diff --git a/var/mongoose/html/edit/script.js b/var/mongoose/html/edit/script.js
new file mode 100644
index 0000000..dcbc00b
--- /dev/null
+++ b/var/mongoose/html/edit/script.js
@@ -0,0 +1,107 @@
+
+$(function() {
+
+var file = null;
+var changed = false;
+
+$('button').button();
+$('button.editactive').disable();
+$('#editor').tabsupport().disable();
+
+function loadfile(f)
+{
+ if (!f)
+ f = file;
+
+ $('button.editactive').disable();
+ $('#editor').disable().val('');
+ $('#msg').text('Loading ' + f);
+ $.get('get.jim?file=' + encodeURIComponent(f), function(data) {
+ if (data.match('^>>>'))
+ {
+ $('#msg').text(data);
+ file = null;
+ changed = false;
+ }
+ else
+ {
+ $('#editor').val(data).enable();
+ $('button.editactive').enable();
+ $('#msg').html('Editing ' + f + '');
+ file = f;
+ changed = false;
+ }
+ });
+}
+
+function result(msg)
+{
+ $('#result')
+ .html(msg)
+ .slideDown('slow')
+ .delay(5000)
+ .slideUp('slow');
+}
+
+$('#chooser').fileTree({
+ root: '/',
+ script: 'files.jim',
+ multiFolder: false
+}, function(file) {
+ $('#chooserd').dialog('close');
+ loadfile(file);
+});
+
+$('#chooserd').dialog({
+ title: "Choose File to Edit",
+ modal: true, autoOpen: false,
+ height: '500', width: '600',
+ draggable: true, resizable: true,
+ closeOnEscape: true,
+ buttons: {
+ "Cancel" : function() {$(this).dialog('close');}
+ }
+});
+
+$('#open').click(function() {
+ $('#chooserd').dialog('open');
+});
+
+$('#editor').change(function() {
+ changed = true;
+});
+
+$('#save').click(function() {
+ if (!changed)
+ {
+ result('No changes to save.');
+ return;
+ }
+
+ if (!confirm('Save file?'))
+ return;
+ $.post('put.jim', {
+ 'file': file,
+ 'data': $('#editor').val()
+ }, function(data) {
+ result(data);
+ });
+});
+
+$('#revert').click(function() {
+ if (!changed)
+ {
+ result('No changes to revert.');
+ return;
+ }
+ if (!confirm('Discard changes and re-load file?'))
+ return;
+ loadfile();
+});
+
+$('#back').click(function() {
+ window.location = '/diag/diag.jim';
+ });
+
+});
+
diff --git a/var/mongoose/cgi-bin/edit/style.css b/var/mongoose/html/edit/style.css
similarity index 74%
rename from var/mongoose/cgi-bin/edit/style.css
rename to var/mongoose/html/edit/style.css
index 06a07fd..cf88e22 100644
--- a/var/mongoose/cgi-bin/edit/style.css
+++ b/var/mongoose/html/edit/style.css
@@ -16,3 +16,9 @@ textarea
background: white;
}
+#chooser
+{
+ border: solid 1px #bbb;
+ padding: 5px;
+}
+
diff --git a/var/mongoose/html/edit/test.jim b/var/mongoose/html/edit/test.jim
new file mode 100755
index 0000000..7dfc8bb
--- /dev/null
+++ b/var/mongoose/html/edit/test.jim
@@ -0,0 +1,33 @@
+#!/mod/bin/jimsh
+
+package require cgi
+source /mod/var/mongoose/lib/setup
+
+puts "Content-Type: text/html"
+puts ""
+
+header
+
+puts {
+
+
+
+
+
+
+
+}
+
+footer
+
diff --git a/var/mongoose/html/img/filetree/application.png b/var/mongoose/html/img/filetree/application.png
new file mode 100644
index 0000000..1dee9e3
Binary files /dev/null and b/var/mongoose/html/img/filetree/application.png differ
diff --git a/var/mongoose/html/img/filetree/code.png b/var/mongoose/html/img/filetree/code.png
new file mode 100644
index 0000000..0c76bd1
Binary files /dev/null and b/var/mongoose/html/img/filetree/code.png differ
diff --git a/var/mongoose/html/img/filetree/css.png b/var/mongoose/html/img/filetree/css.png
new file mode 100644
index 0000000..f907e44
Binary files /dev/null and b/var/mongoose/html/img/filetree/css.png differ
diff --git a/var/mongoose/html/img/filetree/db.png b/var/mongoose/html/img/filetree/db.png
new file mode 100644
index 0000000..bddba1f
Binary files /dev/null and b/var/mongoose/html/img/filetree/db.png differ
diff --git a/var/mongoose/html/img/filetree/directory.png b/var/mongoose/html/img/filetree/directory.png
new file mode 100644
index 0000000..784e8fa
Binary files /dev/null and b/var/mongoose/html/img/filetree/directory.png differ
diff --git a/var/mongoose/html/img/filetree/doc.png b/var/mongoose/html/img/filetree/doc.png
new file mode 100644
index 0000000..ae8ecbf
Binary files /dev/null and b/var/mongoose/html/img/filetree/doc.png differ
diff --git a/var/mongoose/html/img/filetree/file.png b/var/mongoose/html/img/filetree/file.png
new file mode 100644
index 0000000..8b8b1ca
Binary files /dev/null and b/var/mongoose/html/img/filetree/file.png differ
diff --git a/var/mongoose/html/img/filetree/film.png b/var/mongoose/html/img/filetree/film.png
new file mode 100644
index 0000000..b0ce7bb
Binary files /dev/null and b/var/mongoose/html/img/filetree/film.png differ
diff --git a/var/mongoose/html/img/filetree/flash.png b/var/mongoose/html/img/filetree/flash.png
new file mode 100644
index 0000000..5769120
Binary files /dev/null and b/var/mongoose/html/img/filetree/flash.png differ
diff --git a/var/mongoose/html/img/filetree/folder_open.png b/var/mongoose/html/img/filetree/folder_open.png
new file mode 100644
index 0000000..4e35483
Binary files /dev/null and b/var/mongoose/html/img/filetree/folder_open.png differ
diff --git a/var/mongoose/html/img/filetree/html.png b/var/mongoose/html/img/filetree/html.png
new file mode 100644
index 0000000..6ed2490
Binary files /dev/null and b/var/mongoose/html/img/filetree/html.png differ
diff --git a/var/mongoose/html/img/filetree/java.png b/var/mongoose/html/img/filetree/java.png
new file mode 100644
index 0000000..b7bfcd1
Binary files /dev/null and b/var/mongoose/html/img/filetree/java.png differ
diff --git a/var/mongoose/html/img/filetree/linux.png b/var/mongoose/html/img/filetree/linux.png
new file mode 100644
index 0000000..52699bf
Binary files /dev/null and b/var/mongoose/html/img/filetree/linux.png differ
diff --git a/var/mongoose/html/img/filetree/music.png b/var/mongoose/html/img/filetree/music.png
new file mode 100644
index 0000000..a8b3ede
Binary files /dev/null and b/var/mongoose/html/img/filetree/music.png differ
diff --git a/var/mongoose/html/img/filetree/pdf.png b/var/mongoose/html/img/filetree/pdf.png
new file mode 100644
index 0000000..8f8095e
Binary files /dev/null and b/var/mongoose/html/img/filetree/pdf.png differ
diff --git a/var/mongoose/html/img/filetree/php.png b/var/mongoose/html/img/filetree/php.png
new file mode 100644
index 0000000..7868a25
Binary files /dev/null and b/var/mongoose/html/img/filetree/php.png differ
diff --git a/var/mongoose/html/img/filetree/picture.png b/var/mongoose/html/img/filetree/picture.png
new file mode 100644
index 0000000..4a158fe
Binary files /dev/null and b/var/mongoose/html/img/filetree/picture.png differ
diff --git a/var/mongoose/html/img/filetree/ppt.png b/var/mongoose/html/img/filetree/ppt.png
new file mode 100644
index 0000000..c4eff03
Binary files /dev/null and b/var/mongoose/html/img/filetree/ppt.png differ
diff --git a/var/mongoose/html/img/filetree/psd.png b/var/mongoose/html/img/filetree/psd.png
new file mode 100644
index 0000000..73c5b3f
Binary files /dev/null and b/var/mongoose/html/img/filetree/psd.png differ
diff --git a/var/mongoose/html/img/filetree/ruby.png b/var/mongoose/html/img/filetree/ruby.png
new file mode 100644
index 0000000..f59b7c4
Binary files /dev/null and b/var/mongoose/html/img/filetree/ruby.png differ
diff --git a/var/mongoose/html/img/filetree/script.png b/var/mongoose/html/img/filetree/script.png
new file mode 100644
index 0000000..63fe6ce
Binary files /dev/null and b/var/mongoose/html/img/filetree/script.png differ
diff --git a/var/mongoose/html/img/filetree/spinner.gif b/var/mongoose/html/img/filetree/spinner.gif
new file mode 100644
index 0000000..85b99d4
Binary files /dev/null and b/var/mongoose/html/img/filetree/spinner.gif differ
diff --git a/var/mongoose/html/img/filetree/txt.png b/var/mongoose/html/img/filetree/txt.png
new file mode 100644
index 0000000..813f712
Binary files /dev/null and b/var/mongoose/html/img/filetree/txt.png differ
diff --git a/var/mongoose/html/img/filetree/xls.png b/var/mongoose/html/img/filetree/xls.png
new file mode 100644
index 0000000..b977d7e
Binary files /dev/null and b/var/mongoose/html/img/filetree/xls.png differ
diff --git a/var/mongoose/html/img/filetree/zip.png b/var/mongoose/html/img/filetree/zip.png
new file mode 100644
index 0000000..fd4bbcc
Binary files /dev/null and b/var/mongoose/html/img/filetree/zip.png differ
diff --git a/var/mongoose/html/index.shtml b/var/mongoose/html/index.shtml
index 82acde0..6e97ade 100644
--- a/var/mongoose/html/index.shtml
+++ b/var/mongoose/html/index.shtml
@@ -117,7 +117,7 @@ Release Notes:
Firmware |
Webif
-Diagnostics
+Diagnostics & Utilities
Channel Information
diff --git a/var/mongoose/html/js/enadis.js b/var/mongoose/html/js/enadis.js
index fb91ac1..ccbc988 100755
--- a/var/mongoose/html/js/enadis.js
+++ b/var/mongoose/html/js/enadis.js
@@ -5,6 +5,7 @@
return this.each(function() {
$(this)
.removeClass('ui-state-disabled')
+ .removeClass('ui-button-disabled')
.removeProp('disabled');
});
};
diff --git a/var/mongoose/html/js/jqueryFileTree.js b/var/mongoose/html/js/jqueryFileTree.js
new file mode 100644
index 0000000..aa387ca
--- /dev/null
+++ b/var/mongoose/html/js/jqueryFileTree.js
@@ -0,0 +1,94 @@
+// jQuery File Tree Plugin
+//
+// Version 1.01
+//
+// Cory S.N. LaViska
+// A Beautiful Site (http://abeautifulsite.net/)
+// 24 March 2008
+//
+// Visit http://abeautifulsite.net/notebook.php?article=58 for more information
+//
+// Usage: $('.fileTreeDemo').fileTree( options, callback )
+//
+// Options: root - root folder to display; default = /
+// script - location of the serverside AJAX file to use; default = jqueryFileTree.php
+// folderEvent - event to trigger expand/collapse; default = click
+// expandSpeed - default = 500 (ms); use -1 for no animation
+// collapseSpeed - default = 500 (ms); use -1 for no animation
+// expandEasing - easing function to use on expand (optional)
+// collapseEasing - easing function to use on collapse (optional)
+// multiFolder - whether or not to limit the browser to one subfolder at a time
+// loadMessage - Message to display while initial tree loads (can be HTML)
+//
+// History:
+//
+// 1.01 - updated to work with foreign characters in directory/file names (12 April 2008)
+// 1.00 - released (24 March 2008)
+//
+// TERMS OF USE
+//
+// This plugin is dual-licensed under the GNU General Public License and the MIT License and
+// is copyright 2008 A Beautiful Site, LLC.
+//
+if(jQuery) (function($){
+
+ $.extend($.fn, {
+ fileTree: function(o, h) {
+ // Defaults
+ if( !o ) var o = {};
+ if( o.root == undefined ) o.root = '/';
+ if( o.script == undefined ) o.script = 'jqueryFileTree.php';
+ if( o.folderEvent == undefined ) o.folderEvent = 'click';
+ if( o.expandSpeed == undefined ) o.expandSpeed= 750;
+ if( o.collapseSpeed == undefined ) o.collapseSpeed= 750;
+ if( o.expandEasing == undefined ) o.expandEasing = null;
+ if( o.collapseEasing == undefined ) o.collapseEasing = null;
+ if( o.multiFolder == undefined ) o.multiFolder = true;
+ if( o.loadMessage == undefined ) o.loadMessage = 'Loading...';
+
+ $(this).each( function() {
+
+ function showTree(c, t) {
+ $(c).addClass('wait');
+ $(".jqueryFileTree.start").remove();
+ $.post(o.script, { dir: t }, function(data) {
+ $(c).find('.start').html('');
+ $(c).removeClass('wait').append(data);
+ if( o.root == t ) $(c).find('UL:hidden').show(); else $(c).find('UL:hidden').slideDown({ duration: o.expandSpeed, easing: o.expandEasing });
+ bindTree(c);
+ });
+ }
+
+ function bindTree(t) {
+ $(t).find('LI A').bind(o.folderEvent, function() {
+ if( $(this).parent().hasClass('directory') ) {
+ if( $(this).parent().hasClass('collapsed') ) {
+ // Expand
+ if( !o.multiFolder ) {
+ $(this).parent().parent().find('UL').slideUp({ duration: o.collapseSpeed, easing: o.collapseEasing });
+ $(this).parent().parent().find('LI.directory').removeClass('expanded').addClass('collapsed');
+ }
+ $(this).parent().find('UL').remove(); // cleanup
+ showTree( $(this).parent(), $(this).attr('rel') );
+ $(this).parent().removeClass('collapsed').addClass('expanded');
+ } else {
+ // Collapse
+ $(this).parent().find('UL').slideUp({ duration: o.collapseSpeed, easing: o.collapseEasing });
+ $(this).parent().removeClass('expanded').addClass('collapsed');
+ }
+ } else {
+ h($(this).attr('rel'));
+ }
+ return false;
+ });
+ // Prevent A from triggering the # on non-click events
+ if( o.folderEvent.toLowerCase != 'click' ) $(t).find('LI A').bind('click', function() { return false; }); }
+ // Loading message
+ $(this).html('');
+ // Get the initial file list
+ showTree( $(this), o.root);
+ });
+ }
+ });
+
+})(jQuery);
diff --git a/var/mongoose/include/logfiles.jim b/var/mongoose/include/logfiles.jim
deleted file mode 100755
index d87ff87..0000000
--- a/var/mongoose/include/logfiles.jim
+++ /dev/null
@@ -1,14 +0,0 @@
-#!/mod/bin/jimsh
-
-source /mod/var/mongoose/lib/setup
-require pretty_size
-
-foreach file [concat \
- [glob -nocomplain /var/log/*.log] \
- [glob -nocomplain /mod/tmp/*.log] \
-] {
- puts "
-
- [file tail $file] ([pretty_size [file size $file]])
"
-}
-