summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorTed Trask <ttrask01@yahoo.com>2015-11-20 22:57:06 +0000
committerTed Trask <ttrask01@yahoo.com>2015-11-20 22:57:06 +0000
commitda67a7c45fa1fb4cd3eb48a531a9d07a97410d67 (patch)
tree0d1e02b097028768dddaca32e9eec11200eb9df8
parent6938774abb1b40f6c8ce4dc8d94bcb85d4093a1e (diff)
downloadacf-freeswitch-da67a7c45fa1fb4cd3eb48a531a9d07a97410d67.tar.bz2
acf-freeswitch-da67a7c45fa1fb4cd3eb48a531a9d07a97410d67.tar.xz
Replace convertsize function with orig_size
-rw-r--r--freeswitch-listfiles-html.lsp16
1 files changed, 1 insertions, 15 deletions
diff --git a/freeswitch-listfiles-html.lsp b/freeswitch-listfiles-html.lsp
index 7192fe4..9dd7e87 100644
--- a/freeswitch-listfiles-html.lsp
+++ b/freeswitch-listfiles-html.lsp
@@ -3,20 +3,6 @@ htmlviewfunctions = require("htmlviewfunctions")
html = require("acf.html")
%>
-<%
-function convertsize(size)
- if string.find(size, "k$") then
- return tonumber(string.match(size, "[%d.]*")) * 1024.0
- elseif string.find(size, "M$") then
- return tonumber(string.match(size, "[%d.]*")) * 1024.0 * 1024.0
- elseif string.find(size, "G$") then
- return tonumber(string.match(size, "[%d.]*")) + 1024.0 * 1024.0 * 1024.0
- else
- return tonumber(string.match(size, "[%d.]*"))
- end
-end
-%>
-
<script type="text/javascript">
if (typeof jQuery == 'undefined') {
document.write('<script type="text/javascript" src="<%= html.html_escape(page_info.wwwprefix) %>/js/jquery-latest.js"><\/script>');
@@ -65,7 +51,7 @@ end %>
<% end %>
</td>
<td><%= html.html_escape(v.filename) %></td>
- <td><span class="hide"><%= convertsize(v.size) %>b</span><%= html.html_escape(v.size) %></td>
+ <td><span class="hide"><%= html.html_escape(v.orig_size) %>b</span><%= html.html_escape(v.size) %></td>
<td><%= html.html_escape(v.mtime) %></td>
</tr>
<% end %>