Update clip_list.php
This commit is contained in:
parent
f56a8eed60
commit
779e8eed67
|
|
@ -30,7 +30,7 @@
|
|||
require_once "resources/check_auth.php";
|
||||
|
||||
//check permissions
|
||||
if (permission_exists('script_editor_view')) {
|
||||
if (permission_exists('clip_view')) {
|
||||
//access granted
|
||||
}
|
||||
else {
|
||||
|
|
@ -45,11 +45,12 @@
|
|||
$language = new text;
|
||||
$text = $language->get();
|
||||
|
||||
|
||||
//check if this is a file
|
||||
function isfile($filename) {
|
||||
return @filesize($filename) > 0 ? true : false;
|
||||
}
|
||||
|
||||
//count the spaces
|
||||
function space($count) {
|
||||
$r=''; $i=0;
|
||||
while($i < $count) {
|
||||
|
|
@ -59,6 +60,7 @@ function space($count) {
|
|||
return $r;
|
||||
}
|
||||
|
||||
//setup ajax
|
||||
echo "<script type=\"text/javascript\" language=\"javascript\">\n";
|
||||
echo " function makeRequest(url, strpost) {\n";
|
||||
echo " var http_request = false;\n";
|
||||
|
|
@ -118,6 +120,7 @@ echo "\n";
|
|||
echo " }\n";
|
||||
echo "</script>";
|
||||
|
||||
//setup the tree view
|
||||
//echo "// ---------------------------------------------\n";
|
||||
//echo "// --- http://www.codeproject.com/jscript/dhtml_treeview.asp\n";
|
||||
//echo "// --- Name: Easy DHTML Treeview --\n";
|
||||
|
|
@ -154,6 +157,7 @@ key_press('backspace', 'down', 'window', null, null, 'return false;', true);
|
|||
//keyboard shortcut to execute command (when included on command page)
|
||||
key_press('ctrl+enter', 'down', 'window', null, null, "if (!parent.document.getElementById('sidebar')) { parent.$('form#frm').submit(); return false; }", true);
|
||||
|
||||
//show the content
|
||||
echo "</head>\n";
|
||||
echo "<body style='margin: 0; padding: 5px;' onfocus='blur();'>\n";
|
||||
|
||||
|
|
@ -206,7 +210,7 @@ if (is_array($result) && @sizeof($result) != 0) {
|
|||
echo "<div style='white-space: nowrap;'>\n";
|
||||
echo "<a href='javascript:void(0);' onclick=\"parent.insert_clip(document.getElementById('before_".$sub_arr['uuid']."').value, document.getElementById('after_".$sub_arr['uuid']."').value);\">";
|
||||
echo "<img src='resources/images/icon_file.png' border='0' align='absmiddle' style='margin: 1px 2px 3px -1px;'>";
|
||||
echo $sub_arr['name'];
|
||||
echo escape($sub_arr['name']);
|
||||
echo "</a>\n";
|
||||
echo "<textarea style='display: none' id='before_".$sub_arr['uuid']."'>".$sub_arr['before']."</textarea>\n";
|
||||
echo "<textarea style='display: none' id='after_".$sub_arr['uuid']."'>".$sub_arr['after']."</textarea>\n";
|
||||
|
|
@ -217,7 +221,6 @@ if (is_array($result) && @sizeof($result) != 0) {
|
|||
}
|
||||
parse_array($master_array);
|
||||
}
|
||||
|
||||
echo "</div>\n";
|
||||
|
||||
//inclue the footer
|
||||
|
|
|
|||
Loading…
Reference in New Issue