0 && !empty($specific_user_groups)) { $message = str_replace("[existing_tile_ref]", $existing_tile_ref, $lang["existingdashtilefound-2"]) ; } $tile = create_dash_tile($buildurl, $link, $title, $reload_interval, $all_users, $default_order_by, $resource_count, $text, 1, $specific_user_groups); if ($all_users || (!$all_users && !empty($specific_user_groups))) { log_activity($lang['manage_all_dash'], LOG_CODE_CREATED, $title . ($text == '' ? '' : " ({$text})"), 'dash_tile', null, $tile); } else { $existing = add_user_dash_tile($userref, $tile, $default_order_by); if (isset($existing[0])) { $error = $lang["existingdashtilefound"]; } } } /* SAVE SUCCESSFUL? */ if (!$error && !$message) { redirect($baseurl); exit(); } include "../include/header.php"; ?>

/>
'; $validpage = true; $submittext = $lang["create"]; } elseif ($edit) { #edit contains the dash_tile record ref $tile = get_tile($edit); $allusers = $tile["all_users"]; $url = $tile["url"]; $link = $tile["link"]; $title = $tile["title"]; $resource_count = $tile["resource_count"]; $current_specific_user_groups = get_tile_user_groups($edit); if (!can_edit_tile($tile['ref'], $allusers, $userref)) { $validpage = false; } else { #Get field data $buildstring = explode('?', $tile["url"]); if (isset($buildstring[1])) { parse_str(str_replace("&", "&", $buildstring[1]), $buildstring); } if (isset($buildstring["tltype"])) { $tile_type = $buildstring["tltype"]; $tile_nostyle = isset($buildstring["tlstyle"]) && $tile_type != "conf" ? false : true; $tile_style = $buildstring["tlstyle"]; $tile_style_colour = ''; if (allow_tile_colour_change($tile_type) && isset($buildstring['tlstylecolour'])) { $tile_style_colour = $buildstring['tlstylecolour']; } } else { $tile_type = ""; $tile_nostyle = true; } if (!isset($tile_style)) { $tile_style = ""; } # Show freetext field if the tile style is not analytics if ($tile_style != 'analytics') { $freetext = empty($tile["txt"]) ? "true" : $tile["txt"]; } else { $freetext = false; } $promoted_resource = isset($buildstring["promimg"]) ? (int) $buildstring["promimg"] : true; $tlsize = (isset($buildstring['tlsize']) && 'double' === $buildstring['tlsize'] ? $buildstring['tlsize'] : ''); $modifylink = ($tile_type == "ftxt") ? true : false; $notitle = isset($buildstring["nottitle"]) ? true : false; $pagetitle = $lang["editdashtile"]; $formextra = ''; $formextra .= ''; $validpage = true; $submittext = $lang["save"]; } } /* Start Display*/ include "../include/header.php"; if (!$validpage) { echo "

" . escape($lang["error"]) . "

"; echo "

" . escape($lang["error-dashactionmissing"]) . "

"; include "../include/footer.php"; exit; } ?>


/>
(int) $link_parts["parent"])) : 0); $parent_col_data = get_collection($parent); $parent_col_data = (is_array($parent_col_data) ? $parent_col_data : array()); $resources = dash_tile_featured_collection_get_resources($parent_col_data, array()); // The resource manually selected for a category doesn't have to be part of the branch (or any FCs). Add it // to the list of resources as if it is. if ( !empty($parent_col_data) && $parent_col_data["thumbnail_selection_method"] == $FEATURED_COLLECTION_BG_IMG_SELECTION_OPTIONS["manual"] && $parent_col_data["bg_img_resource_ref"] > 0 && get_resource_access($parent_col_data["bg_img_resource_ref"]) == RESOURCE_ACCESS_FULL ) { $resources[] = array( "ref" => $parent_col_data["bg_img_resource_ref"], "field{$view_title_field}" => get_data_by_field($parent_col_data["bg_img_resource_ref"], $view_title_field) ); } if (!is_numeric($promoted_resource)) { $promoted_resource = dash_tile_featured_collection_get_resources($parent_col_data, array("limit" => 1, "use_thumbnail_selection_method" => true)); $promoted_resource = (!empty($promoted_resource) ? $promoted_resource[0]["ref"] : 0); } } if (count($resources) > 0) { ?>
/> /> />