blob: b7b494e445522d676341b5b8b1434bf5e54e431e (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
|
<?php defined("SYSPATH") or die("No direct script access.") ?>
<script type="text/javascript">
$("#<?= $tree_id ?>").ready(function() {
$("#<?= $tree_id ?> span.ui-icon").click(function(event) {
open_close_branch(this, event);
});
$("#<?= $tree_id ?> :checkbox").click(function(event) {
checkbox_click(this, event);
});
});
</script>
<ul id="<?= $tree_id ?>" class="gCheckboxTree">
<? foreach ($data as $file => $file_info): ?>
<li class="<?= empty($file_info["is_dir"]) ? "gFile" : "gDirectory gCollapsed ui-icon-left" ?>">
<? if (!empty($file_info["is_dir"])): ?>
<span class="ui-icon ui-icon-plus"></span>
<? endif ?>
<label> <?= form::checkbox("checkbox[]", p::clean($file_info["path"])) . " " . p::clean($file) ?> </label>
</li>
<? endforeach ?>
</ul>
|