Exemplo n.º 1
0
function listFolderContent($folderID, $username = "", $path = "", $edit = false)
{
    global $style;
    $fields = array('id', 'title', 'pid', 'description');
    $where = array('pid' => $folderID);
    if ($folderID == MAIN_FID) {
        $where['name'] = $username;
    }
    $folders = Prototype::queryData($fields, "folders", $where, false, $path, false, "title");
    foreach ($folders as $key => $current_folder) {
        $fields = array('count(*) as count');
        $where = array('folderid' => $current_folder['id']);
        //$countFolderBookmarks = Prototype::queryData($fields, "favourites", $where, false, $path, false);
        echo "\t<li class=\"treeItem folderHover\" id=\"f" . $current_folder['id'] . "\"><img src=\"" . $path . "images/style/{$style}/folder.GIF\" alt=\"Folder\" title=\"Folder\"/> <span class=\"textHolder\"><span class=\"folder_desc\" title=\"" . $current_folder['description'] . "\">" . $current_folder['title'] . "</span>";
        if ($edit) {
            echo " <a href=\"modifyfolder.php?id=" . $current_folder['id'] . "\" class=\"editF\"><img src=\"images/books/modifyGray.GIF\" width=\"16\" height=\"16\" alt=\"" . T_("Edit") . "\" title=\"" . T_("Edit") . "\" /></a>";
            ?>
			<script type="text/javascript">
				document.write(" <a href=\"#\" onclick=\"deleteFolder(this, <?php 
            echo $current_folder['id'];
            ?>
); return false;\" class=\"deleteF\"><img src=\"images/books/deleteGray.GIF\" width=\"16\" height=\"16\" alt=\"<?php 
            echo T_("Delete");
            ?>
\" title=\"<?php 
            echo T_("Delete");
            ?>
\" /><\/a>");
			</script>
			<?php 
        }
        echo "</span>\n\t\t<ul id=\"f" . $current_folder['id'] . "\" style=\"display: none;\">\n";
        // Retrive sub-folders recusively
        listFolderContent($current_folder['id'], "", $path, $edit);
        // Retrieve folders bookmarks for now
        listFolderBookmarks($current_folder['id'], "", $path, $edit);
        echo "\t\t</ul>\n</li>\n";
    }
}
Exemplo n.º 2
0
You should have received a copy of the GNU General Public License
along with GetBoo; if not, write to the Free Software
Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
***************************************************************************/
require_once 'includes/tags_functions.php';
?>
<div class="tags_rightmenu">
<?php 
if (in_array('profile', $blocks)) {
    require_once 'includes/user.php';
    if (IS_GETBOO) {
        if (User::isDonor($userName)) {
            // Retrieve profile info
            $fields = array('realname', 'displayemail', 'website', 'information', 'email');
            $where = array('name' => $userName);
            $data = Prototype::queryData($fields, "session", $where);
            $donorContent = "" . T_("Name") . ": " . $data[0]['realname'] . "<br>\n";
            $donorContent .= "" . T_("Website") . ": <a href=\"" . $data[0]['website'] . "\">" . $data[0]['website'] . "</a><br>\n";
            $donorContent .= "" . T_("Information") . ":<br>\n<textarea cols=\"30\" rows=\"4\" readonly=\"readonly\">" . $data[0]['information'] . "</textarea><br>\n";
            ?>
	<div class="rm_heading"><?php 
            echo T_("Donor Profile");
            ?>
</div>
	<div class="rm_content"><?php 
            echo "<p>" . $donorContent . "</p>";
            ?>
</div>
	<?php 
            if ($data[0]['displayemail']) {
                ?>