{ ?> <h2><a onclick="return CentralSpaceLoad(this, true);" href="<?php echo $baseurl_short; ?>pages/collection_manage.php"><?php echo $lang['mycollections']; ?></a></h2> <?php } ?> </div> <!--Menu--> <div id="CollectionMinRightNav"> <a id="toggleThumbsLink" href="#" onClick="ToggleThumbs();return false;"><?php echo $lang['showthumbnails']; ?></a> <?php hook('aftertogglethumbs'); // Render dropdown actions render_actions($cinfo, false, false, "min"); ?> </div> <!--Collection Dropdown--> <?php if(!hook('replace_collectionmindroptitle')) { ?> <div id="CollectionMinDropTitle"><?php echo $lang['currentcollection']; ?>: </div> <?php } # end hook replace_collectionmindroptitle ?> <div id="CollectionMinDrop"> <form method="get" id="colselect2"
function DisplayTheme($themes = array(), $simpleview = false) { if ($simpleview) { global $baseurl_short; $getthemes = get_themes($themes); # Themes for ($m = 0; $m < count($getthemes); $m++) { ?> <a href="<?php echo $baseurl_short; ?> pages/search.php?search=!collection<?php echo $getthemes[$m]["ref"]; ?> " onclick="return CentralSpaceLoad(this,true);" class="FeaturedSimplePanel HomePanel DashTile FeaturedSimpleLink" id="advertising_tile_<?php echo $getthemes[$m]["ref"]; ?> "> <div class="FeaturedSimpleTile"> <div id="FeaturedSimpleTileContents_<?php echo $getthemes[$m]["ref"]; ?> " class="HomePanelIN FeaturedSimpleTileContents" > <h2><?php echo i18n_get_collection_name($getthemes[$m]); ?> </h2> </div> </div> </a> <?php } } else { global $theme_direct_jump, $themes_column_sorting, $themes_ref_column, $themes_date_column, $baseurl_short, $baseurl, $default_perpage_list, $collection_prefix, $revsort, $sort, $find, $getthemes, $m, $lang, $flag_new_themes, $contact_sheet, $theme_images, $allow_share, $zipcommand, $collection_download, $theme_images_align_right, $themes_category_split_pages, $themes_category_split_pages_parents, $collections_compact_style, $pagename, $show_edit_all_link, $preview_all, $userref, $collection_purge, $themes_category_split_pages, $themes_category_split_pages_parents_root_node, $enable_theme_category_sharing, $enable_theme_category_edit, $show_theme_collection_stats, $lastlevelchange, $themes_single_collection_shortcut, $download_usage; $themes_order_by = getvalescaped("themes_order_by", getvalescaped("saved_themes_order_by", "name")); $sort = getvalescaped("sort", getvalescaped("saved_themes_sort", "ASC")); $revsort = $sort == "ASC" ? "DESC" : "ASC"; # pager $per_page = getvalescaped("per_page_list", $default_perpage_list, true); $collection_valid_order_bys = array("name", "c"); // sorting doesn't work for nonsplit if (!$themes_column_sorting || !$themes_category_split_pages || $theme_direct_jump) { $sort = "ASC"; $themes_order_by = "name"; $themes_column_sorting = false; } if ($themes_ref_column) { $collection_valid_order_bys[] = "ref"; } if ($themes_date_column) { $collection_valid_order_bys[] = "created"; } $modified_collection_valid_order_bys = hook("modifycollectionvalidorderbys"); if ($modified_collection_valid_order_bys) { $collection_valid_order_bys = $modified_collection_valid_order_bys; } if (!in_array($themes_order_by, $collection_valid_order_bys)) { $sort = "ASC"; $themes_order_by = "name"; } # Check the value is one of the valid values (SQL injection filter) # Work out theme name $themecount = count($themes); for ($x = 0; $x < $themecount; $x++) { if (isset($themes[$x]) && !isset($themes[$x + 1])) { $themename = i18n_get_translated($themes[$x]); } } $getthemes = get_themes($themes); $tmp = hook("getthemesdisp", "", array($themes)); if ($tmp !== false) { $getthemes = $tmp; } if (!$themes_single_collection_shortcut && count($getthemes) > 0 || $themes_single_collection_shortcut && count($getthemes) > 1) { ?> <div class="RecordBox"> <div class="RecordPanel"> <div class="RecordHeader"> <?php if ($themes_category_split_pages && $themes_category_split_pages_parents) { ?> <h1><?php echo $lang["collections"]; ?> </h1><?php } // count total items in themes $totalcount = 0; for ($m = 0; $m < count($getthemes); $m++) { $totalcount = $totalcount + $getthemes[$m]['c']; } if ($theme_images_align_right) { ?> <div style="float:right;"> <?php } $images = get_theme_image($themes); $modified_images = hook("modify_theme_images", '', array($themes)); if (!empty($modified_images)) { $images = $modified_images; } if ($images !== false && $theme_images) { for ($n = 0; $n < count($images); $n++) { ?> <div style="float:left;margin-right:12px;"><img class="CollectImageBorder" src="<?php echo get_resource_path($images[$n], false, "col", false); ?> " /></div> <?php } } if ($theme_images_align_right) { ?> </div> <?php } $themeslinks = ""; for ($x = 0; $x < count($themes); $x++) { $themeslinks .= "theme" . ($x + 1) . "=" . urlencode($themes[$x]) . "&"; } ?> <table><tr><td style="margin:0px;padding:0px;"> <h1 ><?php if ($themes_category_split_pages && $themes_category_split_pages_parents && !$theme_direct_jump) { if ($themes_category_split_pages_parents_root_node) { ?> <a href="<?php echo $baseurl_short; ?> pages/themes.php" onClick="return CentralSpaceLoad(this,true);"><?php echo $lang["themes"]; ?> </a> / <?php } $themescrumbs = ""; for ($x = 0; $x < count($themes); $x++) { $themescrumbs .= "theme" . ($x + 1) . "=" . urlencode($themes[$x]) . "&"; ?> <a href="<?php echo $baseurl_short; ?> pages/themes.php?<?php echo $themescrumbs; ?> " onClick="return CentralSpaceLoad(this,true);"><?php echo htmlspecialchars(i18n_get_translated($themes[$x])); ?> </a> / <?php } } else { echo stripslashes(str_replace("*", "", $themename)); } ?> </h1></td></tr><tr><td style="margin:0px;padding:0px;"> <?php if ($show_theme_collection_stats || !$themes_category_split_pages && ($enable_theme_category_sharing || $enable_theme_category_edit)) { $linkparams = ""; for ($x = 0; $x < count($themes); $x++) { $linkparams .= "theme" . ($x + 1) . "=" . urlencode($themes[$x]) . "&"; } if ($show_theme_collection_stats) { ?> <p style="clear:none;"><?php $collcount = count($getthemes); echo $collcount == 1 ? $lang["collections-1"] : sprintf(str_replace("%number", "%d", $lang["collections-2"]), $collcount, $totalcount); hook("themeactioninline"); ?> </p> </td><td style="margin:0px;padding:0px;"> <?php } ?> <?php if (!$themes_category_split_pages) { if (checkperm("h") && $enable_theme_category_sharing) { $sharelink = ""; for ($x = 0; $x < count($themes); $x++) { $sharelink .= "theme" . ($x + 1) . "=" . urlencode($themes[$x]) . "&"; } ?> </td><tr><td style="margin:0px;padding:0px;"> <a href="<?php echo $baseurl_short; ?> pages/theme_category_share.php?<?php echo $linkparams; ?> " onClick="return CentralSpaceLoad(this,true);"><?php echo "> " . $lang["share"] . "</a>"; } hook("themeaction"); if ($enable_theme_category_edit && checkperm("t")) { ?> <a href="<?php echo $baseurl_short; ?> pages/theme_edit.php?<?php echo $linkparams . "lastlevelchange=" . $lastlevelchange; ?> " onClick="return CentralSpaceLoad(this,true);"><?php echo "> " . $lang["action-edit"] . "</a>"; } } } ?> </td></tr></table> <!-- The number of collections should never be equal to zero. --> <div class="clearerright"> </div> </div> <?php hook("beforethemelist"); ?> <br /> <div class="Listview" style="margin-top:10px;margin-bottom:5px;clear:left;"> <table border="0" cellspacing="0" cellpadding="0" class="ListviewStyle"> <tr class="ListviewBoxedTitleStyle"> <td class="name"><?php if ($themes_order_by == "name") { ?> <span class="Selected"><?php } if ($themes_column_sorting) { ?> <a href="<?php echo $baseurl_short; ?> pages/themes.php?<?php echo $themeslinks; ?> themes_order_by=name&sort=<?php echo urlencode($revsort); ?> " onClick="return CentralSpaceLoad(this);"><?php } echo $lang["collectionname"]; if ($themes_category_split_pages) { ?> </a><?php } if ($themes_order_by == "name") { ?> <div class="<?php echo htmlspecialchars($sort); ?> "> </div><?php } ?> </td> <?php if ($themes_ref_column) { ?> <td class="ref"><?php if ($themes_order_by == "ref") { ?> <span class="Selected"><?php } if ($themes_column_sorting) { ?> <a href="<?php echo $baseurl_short; ?> pages/themes.php?<?php echo $themeslinks; ?> themes_order_by=ref&sort=<?php echo urlencode($revsort); ?> " onClick="return CentralSpaceLoad(this);"><?php } echo $lang["id"]; if ($themes_category_split_pages) { ?> </a><?php } if ($themes_order_by == "ref") { ?> <div class="<?php echo htmlspecialchars($sort); ?> "> </div><?php } ?> </td> <?php } ?> <?php if ($themes_date_column) { ?> <td class="created"><?php if ($themes_order_by == "created") { ?> <span class="Selected"><?php } if ($themes_column_sorting) { ?> <a href="<?php echo $baseurl_short; ?> pages/themes.php?<?php echo $themeslinks; ?> themes_order_by=created&sort=<?php echo urlencode($revsort); ?> " onClick="return CentralSpaceLoad(this);"><?php } echo $lang["created"]; if ($themes_category_split_pages) { ?> </a><?php } if ($themes_order_by == "created") { ?> <div class="<?php echo htmlspecialchars($sort); ?> "> </div><?php } ?> </td> <?php } ?> <td class="count"><?php if ($themes_order_by == "c") { ?> <span class="Selected"><?php } if ($themes_column_sorting) { ?> <a href="<?php echo $baseurl_short; ?> pages/themes.php?<?php echo $themeslinks; ?> themes_order_by=c&sort=<?php echo urlencode($revsort); ?> " onClick="return CentralSpaceLoad(this);"><?php } echo $lang["itemstitle"]; if ($themes_category_split_pages) { ?> </a><?php } if ($themes_order_by == "c") { ?> <div class="<?php echo htmlspecialchars($sort); ?> "> </div><?php } ?> </td> <?php hook("beforecollectiontoolscolumnheader", "themes", array($themeslinks)); ?> <td class="tools"><div class="ListTools"><?php echo $lang["tools"]; ?> </div></td> </tr> <?php for ($m = 0; $m < count($getthemes); $m++) { ?> <tr <?php hook("collectionlistrowstyle"); ?> > <td class="name" width="50%"><div class="ListTitle"><a href="<?php echo $baseurl_short; ?> pages/search.php?search=!collection<?php echo $getthemes[$m]["ref"]; ?> &bc_from=themes" title="<?php echo $lang["collectionviewhover"]; ?> " onClick="return CentralSpaceLoad(this,true);"><?php echo i18n_get_collection_name($getthemes[$m]); ?> </a> <?php if ($flag_new_themes && time() - strtotime($getthemes[$m]["created"]) < 60 * 60 * 24 * 14) { ?> <div class="NewFlag"><?php echo $lang["newflag"]; ?> </div><?php } ?> </div></td> <?php if ($themes_ref_column) { ?> <td class="ref"><?php echo $getthemes[$m]["ref"]; ?> </td> <?php } ?> <?php if ($themes_date_column) { ?> <td class="created"><?php echo nicedate($getthemes[$m]["created"], true); ?> </td> <?php } ?> <td class="count" width="5%"><?php echo $getthemes[$m]["c"]; ?> </td> <?php hook('beforecollectiontoolscolumn'); ?> <td class="tools" nowrap> <div class="ListTools"> <?php hook('render_themes_list_tools', '', array($getthemes[$m])); render_actions($getthemes[$m], false, false); ?> </div> </td> </tr> <?php } ?> </table> </div> </div> <div class="PanelShadow"> </div> </div> <?php } } }
} else { if (strlen($collections[$n]["theme"]) > 0) { echo $lang["theme"]; } else { echo $lang["public"]; } } ?> </td><?php } hook('beforecollectiontoolscolumn'); ?> <td> <div class="ListTools"> <?php hook('render_resource_collection_list_list_tools', '', array($collections[$n])); render_actions($collections[$n], false, false); ?> </div> </td> </tr> <?php } ?> </table></div> </div> </div> <div class="PanelShadow"></div> </div> <?php }
"><?php echo urlencode($results_display_array[$n]); ?> </option> <?php } } ?> </select> </div> <?php } if (!isset($collectiondata)) { $collectiondata = array(); } render_actions($collectiondata, true); if (!$display_selector_dropdowns && !$perpage_dropdown) { ?> <div class="InpageNavLeftBlock"><?php echo ucfirst($lang["perpage"]); ?> :<br /> <?php for ($n = 0; $n < count($results_display_array); $n++) { ?> <?php if ($per_page == $results_display_array[$n]) { ?> <span class="Selected"><?php echo urlencode($results_display_array[$n]); ?>