本文整理汇总了PHP中MetaTagManager::setWindowTitle方法的典型用法代码示例。如果您正苦于以下问题:PHP MetaTagManager::setWindowTitle方法的具体用法?PHP MetaTagManager::setWindowTitle怎么用?PHP MetaTagManager::setWindowTitle使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类MetaTagManager
的用法示例。
在下文中一共展示了MetaTagManager::setWindowTitle方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: __construct
/**
*
*/
public function __construct(&$po_request, &$po_response, $pa_view_paths = null)
{
parent::__construct($po_request, $po_response, $pa_view_paths);
if ($this->request->config->get('pawtucket_requires_login') && !$this->request->isLoggedIn()) {
$this->response->setRedirect(caNavUrl($this->request, "", "LoginReg", "LoginForm"));
}
caSetPageCSSClasses(array("multisearch"));
MetaTagManager::setWindowTitle($this->request->config->get("app_display_name") . ": " . _t("Search") . ": " . $this->request->getParameter('search', pString));
}
示例2: __construct
public function __construct(&$po_request, &$po_response, $pa_view_paths = null)
{
parent::__construct($po_request, $po_response, $pa_view_paths);
$this->config = caGetFrontConfig();
caSetPageCSSClasses(array("front"));
if ($this->request->config->get('pawtucket_requires_login') && !$this->request->isLoggedIn()) {
$this->response->setRedirect(caNavUrl($this->request, "", "LoginReg", "LoginForm"));
}
MetaTagManager::setWindowTitle($this->request->config->get("app_display_name"));
}
示例3: __construct
public function __construct(&$po_request, &$po_response, $pa_view_paths = null)
{
parent::__construct($po_request, $po_response, $pa_view_paths);
if ($this->request->config->get('pawtucket_requires_login') && !$this->request->isLoggedIn()) {
$this->response->setRedirect(caNavUrl($this->request, "", "LoginReg", "LoginForm"));
}
$this->config = caGetContactConfig();
if (!$this->config->get("contact_email") && !$this->config->get("contact_form_elements")) {
$this->notification->addNotification(_t("Contact form is not configured properly"), __NOTIFICATION_TYPE_ERROR__);
$this->response->setRedirect(caNavUrl($this->request, '', '', ''));
}
MetaTagManager::setWindowTitle($this->request->config->get("app_display_name") . ": " . _t("Contact"));
caSetPageCSSClasses(array("contact"));
}
示例4: _initView
/**
* Initializes editor view with core set of values, loads model with record to be edited and selects user interface to use.
*
* @param $pa_options Array of options. Supported options are:
* ui = The ui_id or editor_code value for the user interface to use. If omitted the default user interface is used.
*/
protected function _initView($pa_options = null)
{
// load required javascript
AssetLoadManager::register('bundleableEditor');
AssetLoadManager::register('imageScroller');
AssetLoadManager::register('datePickerUI');
$vn_set_id = $this->request->getParameter('set_id', pInteger);
$t_set = new ca_sets();
if (!$vn_set_id || !$t_set->load($vn_set_id)) {
// Bad set id
return array(null, null, null, null);
}
// Does user have access to set?
if (!$t_set->haveAccessToSet($this->request->getUserID(), __CA_SET_READ_ACCESS__)) {
return array(null, null, null, null);
}
$t_subject = $this->opo_datamodel->getInstanceByTableNum($t_set->get('table_num'));
$t_ui = new ca_editor_uis();
if (!isset($pa_options['ui']) && !$pa_options['ui']) {
$t_ui->load($this->request->user->getPreference("batch_" . $t_subject->tableName() . "_editor_ui"));
}
if (!$t_ui->getPrimaryKey() && isset($pa_options['ui']['__all__']) && $pa_options['ui']['__all__']) {
if (is_numeric($pa_options['ui']['__all__'])) {
$t_ui->load((int) $pa_options['ui']['__all__']);
}
if (!$t_ui->getPrimaryKey()) {
$t_ui->load(array('editor_code' => $pa_options['ui']['__all__']));
}
}
if (!$t_ui->getPrimaryKey()) {
$t_ui = ca_editor_uis::loadDefaultUI($t_subject->tableName(), $this->request, $t_subject->getTypeID());
}
$this->view->setVar('set_id', $vn_set_id);
$this->view->setVar('t_set', $t_set);
$this->view->setVar('t_subject', $t_subject);
$vn_item_count = $t_set->getItemCount(array('user_id' => $this->request->getUserID()));
$vs_item_name = $vn_item_count == 1 ? $t_subject->getProperty("NAME_SINGULAR") : $t_subject->getProperty("NAME_PLURAL");
MetaTagManager::setWindowTitle(_t("Batch editing %1 %2 with set %3", $vn_item_count, $vs_item_name, $t_set->getLabelForDisplay(true)));
return array($vn_set_id, $t_set, $t_subject, $t_ui);
}
示例5: setDetail
//.........这里部分代码省略.........
$o_context->setCurrentSortDirection($ps_sort_direction);
}
$ps_secondary_sort = "";
}
if (!($ps_sort_direction = $this->request->getParameter("direction", pString))) {
if (!($ps_sort_direction = $o_context->getCurrentSortDirection())) {
$ps_sort_direction = 'asc';
}
}
$o_context->setCurrentSort($ps_sort);
$o_context->setCurrentSecondarySort($ps_secondary_sort);
$o_context->setCurrentSortDirection($ps_sort_direction);
$this->view->setVar('sortBy', is_array($va_sort_by) ? $va_sort_by : null);
$this->view->setVar('sortBySelect', $vs_sort_by_select = is_array($va_sort_by) ? caHTMLSelect("sort", $va_sort_by, array('id' => "sort"), array("value" => $ps_sort)) : '');
$this->view->setVar('sort', $ps_sort);
$va_secondary_sort_by = $this->opo_config->getAssoc("secondarySortBy");
$this->view->setVar('secondarySortBy', is_array($va_secondary_sort_by) ? $va_secondary_sort_by : null);
$this->view->setVar('secondarySortBySelect', $vs_secondary_sort_by_select = is_array($va_secondary_sort_by) ? caHTMLSelect("secondary_sort", $va_secondary_sort_by, array('id' => "secondary_sort"), array("value" => $ps_secondary_sort)) : '');
$this->view->setVar('secondarySort', $ps_secondary_sort);
$this->view->setVar('sortDirection', $ps_sort_direction);
$va_options = array('checkAccess' => $this->opa_access_values, 'no_cache' => true);
$o_browse->execute(array_merge($va_options, array('strictPhraseSearching' => true)));
//
// Facets
//
if ($vs_facet_group = $this->opo_config->get("set_facet_group")) {
$o_browse->setFacetGroup($vs_facet_group);
}
$va_available_facet_list = $this->opo_config->get("availableFacets");
$va_facets = $o_browse->getInfoForAvailableFacets();
if (is_array($va_available_facet_list) && sizeof($va_available_facet_list)) {
foreach ($va_facets as $vs_facet_name => $va_facet_info) {
if (!in_array($vs_facet_name, $va_available_facet_list)) {
unset($va_facets[$vs_facet_name]);
}
}
}
foreach ($va_facets as $vs_facet_name => $va_facet_info) {
$va_facets[$vs_facet_name]['content'] = $o_browse->getFacetContent($vs_facet_name, array("checkAccess" => $this->opa_access_values));
}
$this->view->setVar('facets', $va_facets);
$this->view->setVar('key', $vs_key = $o_browse->getBrowseID());
$this->request->session->setVar('lightbox_last_browse_id', $vs_key);
//
// Current criteria
//
$va_criteria = $o_browse->getCriteriaWithLabels();
if (isset($va_criteria['_search']) && isset($va_criteria['_search']['*'])) {
unset($va_criteria['_search']);
}
$va_criteria_for_display = array();
foreach ($va_criteria as $vs_facet_name => $va_criterion) {
$va_facet_info = $o_browse->getInfoForFacet($vs_facet_name);
foreach ($va_criterion as $vn_criterion_id => $vs_criterion) {
$va_criteria_for_display[] = array('facet' => $va_facet_info['label_singular'], 'facet_name' => $vs_facet_name, 'value' => $vs_criterion, 'id' => $vn_criterion_id);
}
}
$this->view->setVar('criteria', $va_criteria_for_display);
//
// Results
//
$vs_combined_sort = $va_sort_by[$ps_sort];
if ($ps_secondary_sort) {
$vs_combined_sort .= ";" . $va_secondary_sort_by[$ps_secondary_sort];
}
$qr_res = $o_browse->getResults(array('sort' => $vs_combined_sort, 'sort_direction' => $ps_sort_direction));
$this->view->setVar('result', $qr_res);
if (!($pn_hits_per_block = $this->request->getParameter("n", pString))) {
if (!($pn_hits_per_block = $o_context->getItemsPerPage())) {
$pn_hits_per_block = $this->opo_config->get("defaultHitsPerBlock") ? $this->opo_config->get("defaultHitsPerBlock") : 36;
}
}
$o_context->getItemsPerPage($pn_hits_per_block);
$this->view->setVar('hits_per_block', $pn_hits_per_block);
$this->view->setVar('start', $vn_start = $this->request->getParameter('s', pInteger));
$o_context->setParameter('key', $vs_key);
if (($vn_key_start = $vn_start - 500) < 0) {
$vn_key_start = 0;
}
$qr_res->seek($vn_key_start);
$o_context->setResultList($qr_res->getPrimaryKeyValues(1000));
if ($o_block_result_context) {
$o_block_result_context->setResultList($qr_res->getPrimaryKeyValues(1000));
$o_block_result_context->saveContext();
}
$qr_res->seek($vn_start);
$o_context->saveContext();
MetaTagManager::setWindowTitle($this->request->config->get("app_display_name") . ": " . ucfirst($this->ops_lightbox_display_name) . ": " . $t_set->getLabelForDisplay());
switch ($ps_view) {
case 'pdf':
$this->_genExport($qr_res, $this->request->getParameter("export_format", pString), $vs_label = $t_set->get('ca_sets.preferred_labels'), $vs_label);
case 'timelineData':
$this->view->setVar('view', 'timeline');
$this->render("Sets/set_detail_timelineData_json.php");
break;
default:
$this->render("Sets/set_detail_html.php");
break;
}
}
示例6: Index
/**
* Options:
* appendToSearch = optional text to be AND'ed wuth current search expression
* output_format = determines format out search result output. "PDF" and "HTML" are currently supported; "HTML" is the default
* view = view with path relative to controller to use overriding default ("search/<table_name>_search_basic_html.php")
* vars = associative array with key value pairs to assign to the view
*
* Callbacks:
* hookBeforeNewSearch() is called just before executing a new search. The first parameter is the BrowseEngine object containing the search.
*/
public function Index($pa_options = null)
{
$po_search = isset($pa_options['search']) ? $pa_options['search'] : null;
if (isset($pa_options['saved_search']) && $pa_options['saved_search']) {
$this->opo_result_context->setSearchExpression($pa_options['saved_search']['search']);
$this->opo_result_context->isNewSearch(true);
}
parent::Index($pa_options);
AssetLoadManager::register('hierBrowser');
AssetLoadManager::register('browsable');
// need this to support browse panel when filtering/refining search results
$t_model = $this->opo_datamodel->getInstanceByTableName($this->ops_tablename, true);
$va_access_values = caGetUserAccessValues($this->request);
// Get elements of result context
$vn_page_num = $this->opo_result_context->getCurrentResultsPageNumber();
$vs_search = $this->opo_result_context->getSearchExpression();
$vb_is_new_search = $this->opo_result_context->isNewSearch();
if ((bool) $this->request->getParameter('reset', pString) && $this->request->getParameter('reset', pString) != 'save') {
$vs_search = '';
$vb_is_new_search = true;
}
if (!($vn_items_per_page = $this->opo_result_context->getItemsPerPage())) {
$vn_items_per_page = $this->opn_items_per_page_default;
$this->opo_result_context->setItemsPerPage($vn_items_per_page);
}
if (!($vs_view = $this->opo_result_context->getCurrentView())) {
$va_tmp = array_keys($this->opa_views);
$vs_view = $this->ops_view_default ? $this->ops_view_default : array_shift($va_tmp);
$this->opo_result_context->setCurrentView($vs_view);
}
if (!isset($this->opa_views[$vs_view])) {
$va_tmp = array_keys($this->opa_views);
$vs_view = array_shift($va_tmp);
}
if (!($vs_sort = $this->opo_result_context->getCurrentSort())) {
$va_tmp = array_keys($this->opa_sorts);
$vs_sort = array_shift($va_tmp);
}
$vs_sort_direction = $this->opo_result_context->getCurrentSortDirection();
$vb_sort_has_changed = $this->opo_result_context->sortHasChanged();
if (!$this->opn_type_restriction_id) {
$this->opn_type_restriction_id = '';
}
$this->view->setVar('type_id', $this->opn_type_restriction_id);
MetaTagManager::setWindowTitle(_t('%1 search', $this->searchName('plural')));
// Get attribute sorts
$va_sortable_elements = ca_metadata_elements::getSortableElements($this->ops_tablename, $this->opn_type_restriction_id);
if (!is_array($this->opa_sorts)) {
$this->opa_sorts = array();
}
foreach ($va_sortable_elements as $va_sortable_element) {
$this->opa_sorts[$this->ops_tablename . '.' . $va_sortable_element['element_code']] = $va_sortable_element['display_label'];
}
if ($pa_options['appendToSearch']) {
$vs_append_to_search .= " AND (" . $pa_options['appendToSearch'] . ")";
}
//
// Execute the search
//
if ($vs_search && $vs_search != "") {
/* any request? */
$va_search_opts = array('sort' => $vs_sort, 'sort_direction' => $vs_sort_direction, 'appendToSearch' => $vs_append_to_search, 'checkAccess' => $va_access_values, 'no_cache' => $vb_is_new_search, 'dontCheckFacetAvailability' => true, 'filterNonPrimaryRepresentations' => true);
if ($vb_is_new_search || isset($pa_options['saved_search']) || is_subclass_of($po_search, "BrowseEngine") && !$po_search->numCriteria()) {
$vs_browse_classname = get_class($po_search);
$po_search = new $vs_browse_classname();
if (is_subclass_of($po_search, "BrowseEngine")) {
$po_search->addCriteria('_search', $vs_search);
if (method_exists($this, "hookBeforeNewSearch")) {
$this->hookBeforeNewSearch($po_search);
}
}
$this->opo_result_context->setParameter('show_type_id', null);
}
if ($this->opn_type_restriction_id) {
$po_search->setTypeRestrictions(array($this->opn_type_restriction_id), array('includeSubtypes' => false));
}
$vb_criteria_have_changed = false;
if (is_subclass_of($po_search, "BrowseEngine")) {
//
// Restrict facets to specific group for main browse landing page (if set in app.conf config)
//
if ($vs_facet_group = $this->request->config->get($this->ops_tablename . '_search_refine_facet_group')) {
$po_search->setFacetGroup($vs_facet_group);
}
$vb_criteria_have_changed = $po_search->criteriaHaveChanged();
$po_search->execute($va_search_opts);
$this->opo_result_context->setParameter('browse_id', $po_search->getBrowseID());
if ($vs_group_name = $this->request->config->get('browse_facet_group_for_' . $this->ops_tablename)) {
$po_search->setFacetGroup($vs_group_name);
}
//.........这里部分代码省略.........
示例7: __call
/**
*
*/
public function __call($ps_function, $pa_args)
{
$ps_function = strtolower($ps_function);
# --- which type of set is configured for display in gallery section
$t_list = new ca_lists();
$vn_gallery_set_type_id = $t_list->getItemIDFromList('set_types', $this->config->get('gallery_set_type'));
$t_set = new ca_sets();
if ($ps_function == "index") {
if ($vn_gallery_set_type_id) {
$va_sets = caExtractValuesByUserLocale($t_set->getSets(array('table' => 'ca_objects', 'checkAccess' => $this->opa_access_values, 'setType' => $vn_gallery_set_type_id)));
$va_set_first_items = $t_set->getFirstItemsFromSets(array_keys($va_sets), array("version" => "icon", "checkAccess" => $this->opa_access_values));
$o_front_config = caGetFrontConfig();
$vs_front_page_set = $o_front_config->get('front_page_set_code');
$vb_omit_front_page_set = (bool) $this->config->get('omit_front_page_set_from_gallery');
foreach ($va_sets as $vn_set_id => $va_set) {
if ($vb_omit_front_page_set && $va_set['set_code'] == $vs_front_page_set) {
unset($va_sets[$vn_set_id]);
}
}
$this->view->setVar('sets', $va_sets);
$this->view->setVar('first_items_from_sets', $va_set_first_items);
}
MetaTagManager::setWindowTitle($this->request->config->get("app_display_name") . ": " . ($this->config->get('gallery_section_name') ? $this->config->get('gallery_section_name') : _t("Gallery")));
$this->render("Gallery/index_html.php");
} else {
$ps_set_id = $ps_function;
$this->view->setVar("set_id", $ps_set_id);
$t_set->load($ps_set_id);
$this->view->setVar("set", $t_set);
$this->view->setVar("label", $t_set->getLabelForDisplay());
$this->view->setVar("description", $t_set->get($this->config->get('gallery_set_description_element_code')));
$this->view->setVar("set_items", caExtractValuesByUserLocale($t_set->getItems(array("thumbnailVersions" => array("icon"), "checkAccess" => $this->opa_access_values))));
MetaTagManager::setWindowTitle($this->request->config->get("app_display_name") . ": " . ($this->config->get('gallery_section_name') ? $this->config->get('gallery_section_name') : _t("Gallery")) . ": " . $t_set->getLabelForDisplay());
$this->render("Gallery/detail_html.php");
}
}
示例8: __call
/**
*
*/
public function __call($ps_function, $pa_args)
{
AssetLoadManager::register("panel");
AssetLoadManager::register("mediaViewer");
AssetLoadManager::register("carousel");
AssetLoadManager::register("readmore");
AssetLoadManager::register("maps");
$ps_function = strtolower($ps_function);
$ps_id = urldecode($this->request->getActionExtra());
if (!isset($this->opa_detail_types[$ps_function]) || !isset($this->opa_detail_types[$ps_function]['table']) || !($vs_table = $this->opa_detail_types[$ps_function]['table'])) {
// invalid detail type – throw error
die("Invalid detail type");
}
$t_table = $this->opo_datamodel->getInstanceByTableName($vs_table, true);
if (($vb_use_identifiers_in_urls = caUseIdentifiersInUrls()) && substr($ps_id, 0, 3) == "id:") {
$va_tmp = explode(":", $ps_id);
$ps_id = (int) $va_tmp[1];
$vb_use_identifiers_in_urls = false;
}
if (!$t_table->load($vb_use_identifiers_in_urls && $t_table->getProperty('ID_NUMBERING_ID_FIELD') ? $t_table->hasField('deleted') ? array($t_table->getProperty('ID_NUMBERING_ID_FIELD') => $ps_id, 'deleted' => 0) : array($t_table->getProperty('ID_NUMBERING_ID_FIELD') => $ps_id) : ($t_table->hasField('deleted') ? array($t_table->primaryKey() => (int) $ps_id, 'deleted' => 0) : array($t_table->primaryKey() => (int) $ps_id)))) {
// invalid id - throw error
die("Invalid id");
}
// Printables
// merge displays with drop-in print templates
//
$va_export_options = caGetAvailablePrintTemplates('summary', array('table' => $t_table->tableName()));
$this->view->setVar('export_formats', $va_export_options);
$va_options = array();
foreach ($va_export_options as $vn_i => $va_format_info) {
$va_options[$va_format_info['name']] = $va_format_info['code'];
}
// Get current display list
$t_display = new ca_bundle_displays();
foreach (caExtractValuesByUserLocale($t_display->getBundleDisplays(array('table' => $this->ops_tablename, 'user_id' => $this->request->getUserID(), 'access' => __CA_BUNDLE_DISPLAY_READ_ACCESS__, 'checkAccess' => caGetUserAccessValues($this->request)))) as $va_display) {
$va_options[$va_display['name']] = "_display_" . $va_display['display_id'];
}
ksort($va_options);
$this->view->setVar('export_format_select', caHTMLSelect('export_format', $va_options, array('class' => 'searchToolsSelect'), array('value' => $this->view->getVar('current_export_format'), 'width' => '150px')));
#
# Enforce access control
#
if (sizeof($this->opa_access_values) && $t_table->hasField('access') && !in_array($t_table->get("access"), $this->opa_access_values)) {
$this->notification->addNotification(_t("This item is not available for view"), "message");
$this->response->setRedirect(caNavUrl($this->request, "", "", "", ""));
return;
}
MetaTagManager::setWindowTitle($this->request->config->get("app_display_name") . ": " . $t_table->getTypeName() . ": " . $t_table->get('preferred_labels') . (($vs_idno = $t_table->get($t_table->getProperty('ID_NUMBERING_ID_FIELD'))) ? " [{$vs_idno}]" : ""));
$vs_type = $t_table->getTypeCode();
$this->view->setVar('detailType', $vs_table);
$this->view->setVar('item', $t_table);
$this->view->setVar('itemType', $vs_type);
caAddPageCSSClasses(array($vs_table, $ps_function, $vs_type));
// Do we need to pull in the multisearch result set?
if (ResultContext::getLastFind($this->request, $vs_table, array('noSubtype' => true)) === 'multisearch') {
$o_context = new ResultContext($this->request, $vs_table, 'multisearch', $ps_function);
$o_context->setAsLastFind();
$o_context->saveContext();
} else {
$o_context = ResultContext::getResultContextForLastFind($this->request, $vs_table);
}
$this->view->setVar('previousID', $vn_previous_id = $o_context->getPreviousID($t_table->getPrimaryKey()));
$this->view->setVar('nextID', $vn_next_id = $o_context->getNextID($t_table->getPrimaryKey()));
$this->view->setVar('previousURL', caDetailUrl($this->request, $vs_table, $vn_previous_id));
$this->view->setVar('nextURL', caDetailUrl($this->request, $vs_table, $vn_next_id));
$this->view->setVar('resultsURL', ResultContext::getResultsUrlForLastFind($this->request, $vs_table));
$va_options = isset($this->opa_detail_types[$ps_function]['options']) && is_array($this->opa_detail_types[$ps_function]['options']) ? $this->opa_detail_types[$ps_function]['options'] : array();
$this->view->setVar('previousLink', $vn_previous_id > 0 ? caDetailLink($this->request, caGetOption('previousLink', $va_options, _t('Previous')), '', $vs_table, $vn_previous_id) : '');
$this->view->setVar('nextLink', $vn_next_id > 0 ? caDetailLink($this->request, caGetOption('nextLink', $va_options, _t('Next')), '', $vs_table, $vn_next_id) : '');
$this->view->setVar('resultsLink', ResultContext::getResultsLinkForLastFind($this->request, $vs_table, caGetOption('resultsLink', $va_options, _t('Back'))));
$this->view->setVar('commentsEnabled', (bool) $va_options['enableComments']);
//
//
//
if (method_exists($t_table, 'getPrimaryRepresentationInstance')) {
if ($pn_representation_id = $this->request->getParameter('representation_id', pInteger)) {
$t_representation = $this->opo_datamodel->getInstanceByTableName("ca_object_representations", true);
$t_representation->load($pn_representation_id);
} else {
$t_representation = $t_table->getPrimaryRepresentationInstance(array("checkAccess" => $this->opa_access_values));
}
if ($t_representation) {
$this->view->setVar("t_representation", $t_representation);
$this->view->setVar("representation_id", $t_representation->get("representation_id"));
} else {
$t_representation = $this->opo_datamodel->getInstanceByTableName("ca_object_representations", true);
}
$this->view->setVar("representationViewer", caObjectDetailMedia($this->request, $t_table->getPrimaryKey(), $t_representation, $t_table, array("primaryOnly" => caGetOption('representationViewerPrimaryOnly', $va_options, false), "dontShowPlaceholder" => caGetOption('representationViewerDontShowPlaceholder', $va_options, false))));
}
//
// map
//
if (!is_array($va_map_attributes = caGetOption('map_attributes', $va_options, array())) || !sizeof($va_map_attributes)) {
if ($vs_map_attribute = caGetOption('map_attribute', $va_options, false)) {
$va_map_attributes = array($vs_map_attribute);
}
}
//.........这里部分代码省略.........
示例9: caGetThemeGraphicUrl
<?php
MetaTagManager::setWindowTitle($this->request->config->get("app_display_name") . ": Competence Standards");
?>
<div class="container blueBox">
<div class="row">
<div class="col-sm-12">
<p>
All of the materials provided via this Body of Knowledge portal are keyed to the global competence standards defined in the IUCN WCPA Capacity Development Tools. Thus, understanding the competence framework is critical to effectively using the portal.
</p><br/>
</div><!-- end col -->
<div class="col-sm-6 text-right">
<a href="<?php
print caGetThemeGraphicUrl($this->request, 'CompetenceUserGuide_V2_WPC_Nov2014.pdf');
?>
"><button type="button" class="btn btn-blue"><span class="glyphicon glyphicon-download-alt"></span> Competence Standards Handbook</button></a>
</div>
<div class="col-sm-6 text-left">
<a href="<?php
print caGetThemeGraphicUrl($this->request, 'DraftPACompetenceRegisterNov2014forWPC_LOCKED.xlsx');
?>
"><button type="button" class="btn btn-blue"><span class="glyphicon glyphicon-download-alt"></span> Competence Standards Registry</button></a>
</div>
</div><!-- end row -->
</div><!-- end bluebox -->
<div class="container containerTextPadding">
<div class="row">
<div class="col-sm-6">
<p>
<strong>Competence</strong> is the proven ability to do a job; it is often defined in terms of the required combination of skills, knowledge and attitude. <strong>Skills</strong> ensure the ability to perform a task reliably and consistently, <strong>knowledge</strong> provides an understanding of the technical and theoretical background to the task and an appreciation of its purpose; and having the right <strong>attitude</strong> helps ensure than an individual works professionally, ethically and conscientiously. <strong>Competence</strong> focuses primarily on the actual ability of individuals to perform in their jobs effectively, rather than on delivery of training and acquisition of qualifications.
</p>
示例10: Show
//.........这里部分代码省略.........
$this->request->session->setVar($this->ops_tablename . '_' . $this->ops_appname . '_detail_current_browse_id', null);
$this->view->setVar('show_browse', false);
}
}
$this->request->session->setVar($this->ops_tablename . '_' . $this->ops_appname . '_detail_current_item_id', $vn_item_id);
# Next and previous navigation
$opo_result_context = new ResultContext($this->request, $this->ops_tablename, ResultContext::getLastFind($this->request, $this->ops_tablename));
$this->view->setVar('next_id', $opo_result_context->getNextID($vn_item_id));
$this->view->setVar('previous_id', $opo_result_context->getPreviousID($vn_item_id));
# Is the item we're show details for in the result set?
$this->view->setVar('is_in_result_list', $opo_result_context->getIndexInResultList($vn_item_id) != '?');
# Item instance and id
$this->view->setVar('t_item', $t_item);
$this->view->setVar($t_item->getPrimaryKey(), $vn_item_id);
# Item - preferred
$this->view->setVar('label', $t_item->getLabelForDisplay());
# Item - nonpreferred
$this->view->setVar('nonpreferred_labels', caExtractValuesByUserLocale($t_item->getNonPreferredLabels()));
# Item timestamps (creation and last change)
if ($va_entry_info = $t_item->getCreationTimestamp()) {
$this->view->setVar('date_of_entry', date('m/d/Y', $va_entry_info['timestamp']));
}
if ($va_last_change_info = $t_item->getLastChangeTimestamp()) {
$this->view->setVar('date_of_last_change', date('m/d/Y', $va_last_change_info['timestamp']));
}
# Media representations to display (objects only)
if (method_exists($t_item, 'getPrimaryRepresentationInstance')) {
if ($t_primary_rep = $t_item->getPrimaryRepresentationInstance()) {
if (!sizeof($va_access_values) || in_array($t_primary_rep->get('access'), $va_access_values)) {
// check rep access
$this->view->setVar('t_primary_rep', $t_primary_rep);
$va_rep_display_info = caGetMediaDisplayInfo('detail', $t_primary_rep->getMediaInfo('media', 'INPUT', 'MIMETYPE'));
$this->view->setVar('primary_rep_display_version', $va_rep_display_info['display_version']);
unset($va_display_info['display_version']);
$va_rep_display_info['poster_frame_url'] = $t_primary_rep->getMediaUrl('media', $va_rep_display_info['poster_frame_version']);
unset($va_display_info['poster_frame_version']);
$this->view->setVar('primary_rep_display_options', $va_rep_display_info);
}
}
}
#
# User-generated comments, tags and ratings
#
$va_user_comments = $t_item->getComments(null, true);
$va_comments = array();
if (is_array($va_user_comments)) {
foreach ($va_user_comments as $va_user_comment) {
if ($va_user_comment["comment"] || $va_user_comment["media1"] || $va_user_comment["media2"] || $va_user_comment["media3"] || $va_user_comment["media4"]) {
# TODO: format date based on locale
$va_user_comment["date"] = date("n/j/Y", $va_user_comment["created_on"]);
# -- get name of commenter
$t_user = new ca_users($va_user_comment["user_id"]);
$va_user_comment["author"] = $t_user->getName();
$va_comments[] = $va_user_comment;
}
}
}
$this->view->setVar('comments', $va_comments);
$va_user_tags = $t_item->getTags(null, true);
$va_tags = array();
if (is_array($va_user_tags)) {
foreach ($va_user_tags as $va_user_tag) {
if (!in_array($va_user_tag["tag"], $va_tags)) {
$va_tags[] = $va_user_tag["tag"];
}
}
}
$this->view->setVar('tags_array', $va_tags);
$this->view->setVar('tags', implode(", ", $va_tags));
$this->view->setVar('result_context', $opo_result_context);
# -- get average user ranking
$this->view->setVar('ranking', $t_item->getAverageRating(null));
// null makes it ignore moderation status
# -- get number of user rankings
$this->view->setVar('numRankings', $t_item->getNumRatings(null));
// null makes it ignore moderation status
#
# Miscellaneous useful information
#
$this->view->setVar('t_relationship_types', new ca_relationship_types());
// relationship types object - used for displaying relationship type of related authority information
if (method_exists($t_item, 'getTypeName')) {
$this->view->setVar('typename', $t_item->getTypeName());
}
// Record view
$t_item->registerItemView($this->request->getUserID());
MetaTagManager::setWindowTitle("Viewing: " . $t_item->get("preferred_labels"));
//
// Render view
//
if (isset($pa_options['view']) && $pa_options['view']) {
$this->render($pa_options['view']);
} else {
if ($this->getView()->viewExists($this->ops_tablename . '_' . $t_item->getTypeCode() . '_detail_html.php')) {
$this->render($this->ops_tablename . '_' . $t_item->getTypeCode() . '_detail_html.php');
} else {
$this->render($this->ops_tablename . '_detail_html.php');
}
}
}
示例11: Send
/**
* Process form submission
*/
public function Send()
{
global $g_ui_locale_id;
$o_dm = Datamodel::load();
$ps_function = $this->request->getParameter('_contributeFormName', pString);
$va_response_data = array('errors' => array(), 'numErrors' => 0, 'status' => 'OK');
$vn_num_errors = 0;
if (!($va_form_info = $this->_checkForm($ps_function))) {
return;
}
$va_related_form_item_config = caGetOption('related', $va_form_info, array());
$this->view->setVar('t_subject', $t_subject = $this->pt_subject);
$vs_idno_fld_name = $t_subject->getProperty('ID_NUMBERING_ID_FIELD');
$t_subject->clear();
$t_subject->setMode(ACCESS_WRITE);
$t_subject->purify(true);
// run all input through HTMLpurifier
$t_subject->setTransaction($o_trans = new Transaction());
$vs_subject_table = $t_subject->tableName();
$t_subject->set('type_id', $va_form_info['type'] ? $va_form_info['type'] : $this->request->getParameter('type_id', pInteger));
// set type so idno's reflect proper format
// Set window title
MetaTagManager::setWindowTitle(caGetOption('formTitle', $va_form_info, $this->request->config->get("app_display_name") . ": " . _t("Contribute")));
// Get list of form elements to process
$va_fields = explode(';', $this->request->getParameter('_formElements', pString));
// Clean up field names, which PHP has mangled by replacing periods with underscores
if (is_array($va_fields) && sizeof($va_fields) > 0) {
foreach ($va_fields as $vs_orig_fld_name) {
$vs_orig_fld_name_proc = str_replace(".", "_", $vs_orig_fld_name);
$_REQUEST[$vs_orig_fld_name] = $_REQUEST[$vs_orig_fld_name_proc];
unset($_REQUEST[$vs_orig_fld_name_proc]);
}
}
// Check terms
if (caGetOption('terms_and_conditions', $va_form_info, false)) {
// Check terms and conditions checkbox
if ($this->request->getParameter('iAgreeToTerms', pInteger) != 1) {
$this->notification->addNotification(_t("You must agree to the terms and conditions before proceeding."), __NOTIFICATION_TYPE_ERROR__);
$va_response_data['numErrors'] = 1;
$va_response_data['status'] = 'ERR';
$va_response_data['errors']['_general_'][] = _t("You must agree to the terms and conditions before proceeding.");
$va_response_data['formData'] = $_REQUEST;
$this->view->setVar('response', $va_response_data);
$t_subject->getTransaction()->rollback();
call_user_method($ps_function, $this);
return;
}
}
// Spam check
if (caGetOption('spam_protection', $va_form_info, false)) {
// Check SPAM-preventing security question
if ($this->request->getParameter('security', pInteger) != $this->request->getParameter('sum', pInteger)) {
$this->notification->addNotification(_t("Please correctly answer the security question."), __NOTIFICATION_TYPE_ERROR__);
$va_response_data['numErrors'] = 1;
$va_response_data['status'] = 'ERR';
$va_response_data['errors']['_general_'][] = _t("Please correctly answer the security question.");
$va_response_data['formData'] = $_REQUEST;
$this->view->setVar('response', $va_response_data);
$t_subject->getTransaction()->rollback();
call_user_method($ps_function, $this);
return;
}
}
// Set content from form
$vm_type = $vs_idno = $vn_status = $vn_access = null;
$vb_has_media = false;
// Assemble content tree
$va_content_tree = array();
foreach ($va_fields as $vs_field) {
$va_fld_bits = explode(".", $vs_field);
$vs_field_proc = str_replace(".", "_", $vs_field);
// PHP replaces periods in names with underscores :-(
$vs_table = $va_fld_bits[0];
$va_vals = $this->request->getParameter($vs_field_proc, pArray);
if ($vs_subject_table == $vs_table) {
// subject table
switch (sizeof($va_fld_bits)) {
case 2:
case 3:
if ($t_subject->hasField($va_fld_bits[1])) {
// intrinsic
$va_content_tree[$vs_subject_table][$va_fld_bits[1]] = $va_vals[0];
switch ($va_fld_bits[1]) {
case $t_subject->getTypeFieldName():
$vm_type = $va_vals[0];
break;
case $vs_idno_fld_name:
// parse out value
if (method_exists($t_subject, "loadIDNoPlugInInstance") && ($o_numbering_plugin = $t_subject->loadIDNoPlugInInstance(array('IDNumberingConfig' => $this->config)))) {
$vs_idno = $o_numbering_plugin->htmlFormValue($vs_idno_fld_name, null, true);
} else {
$vs_idno = $va_vals[0];
}
break;
case 'status':
$vn_status = (int) $va_vals[0];
break;
//.........这里部分代码省略.........
示例12: __call
/**
*
*/
public function __call($ps_function, $pa_args)
{
$o_config = caGetListingConfig();
$ps_function = strtolower($ps_function);
$ps_type = $this->request->getActionExtra();
if (!($va_listing_info = caGetInfoForListingType($ps_function))) {
// invalid listing type – throw error
die("Invalid listing type");
}
MetaTagManager::setWindowTitle($this->request->config->get("app_display_name") . ": " . $va_listing_info["displayName"]);
$o_dm = Datamodel::load();
$ps_function = strtolower($ps_function);
$vs_table = $va_listing_info['table'];
$vs_search = caGetOption('search', $va_listing_info, '*');
$vs_segment_by = caGetOption('segmentBy', $va_listing_info, '');
$this->opo_result_context = new ResultContext($this->request, $vs_table, $this->ops_find_type);
$this->opo_result_context->setAsLastFind();
if (!($t_instance = $o_dm->getInstanceByTableName($vs_table, true))) {
die("Invalid table");
}
if (!($o_browse = caGetBrowseInstance($vs_table))) {
die("Invalid listing");
}
// Set browse facet group
if ($vs_facet_group = caGetOption('browseFacetGroup', $va_listing_info, null)) {
$o_browse->setFacetGroup($vs_facet_group);
}
$va_types = caGetOption('restrictToTypes', $va_listing_info, array(), array('castTo' => 'array'));
$va_type_list = $t_instance->getTypeList();
if (!is_array($va_types) || !sizeof($va_types)) {
$va_types = array_keys($va_type_list);
} else {
$va_types = caMakeTypeIDList($vs_table, $va_types, array('dontIncludeSubtypesInTypeRestriction' => true));
}
$o_browse->addCriteria("_search", array($vs_search));
$o_browse->setTypeRestrictions($va_types, array('dontExpandHierarchically' => true));
$o_browse->execute(array('checkAccess' => $this->opa_access_values));
//
// Facets for search
//
$va_facets = $o_browse->getInfoForAvailableFacets();
foreach ($va_facets as $vs_facet_name => $va_facet_info) {
$va_facets[$vs_facet_name]['content'] = $o_browse->getFacetContent($vs_facet_name, array('checkAccess' => $this->opa_access_values));
}
$this->view->setVar('facets', $va_facets);
//
// Add criteria and execute
//
if ($vs_facet = $this->request->getParameter('facet', pString)) {
$o_browse->addCriteria($vs_facet, array($vn_facet_id = $this->request->getParameter('id', pString)));
$this->view->setVar('facet', $vs_facet);
$this->view->setVar('facet_id', $vn_facet_id);
}
//
// Sorting
//
$vb_sort_changed = false;
if (!($ps_sort = $this->request->getParameter("sort", pString))) {
if (!($ps_sort = $this->opo_result_context->getCurrentSort())) {
if (is_array($va_sorts = caGetOption('sortBy', $va_listing_info, null))) {
$ps_sort = array_shift(array_keys($va_sorts));
$vb_sort_changed = true;
}
}
} else {
$vb_sort_changed = true;
}
if ($vb_sort_changed) {
# --- set the default sortDirection if available
$va_sort_direction = caGetOption('sortDirection', $va_listing_info, null);
if ($ps_sort_direction = $va_sort_direction[$ps_sort]) {
$this->opo_result_context->setCurrentSortDirection($ps_sort_direction);
}
}
if (!($ps_sort_direction = $this->request->getParameter("direction", pString))) {
if (!($ps_sort_direction = $this->opo_result_context->getCurrentSortDirection())) {
$ps_sort_direction = 'asc';
}
}
$this->opo_result_context->setCurrentSort($ps_sort);
$this->opo_result_context->setCurrentSortDirection($ps_sort_direction);
$va_sort_by = caGetOption('sortBy', $va_listing_info, null);
$this->view->setVar('sortBy', is_array($va_sort_by) ? $va_sort_by : null);
$this->view->setVar('sortBySelect', $vs_sort_by_select = is_array($va_sort_by) ? caHTMLSelect("sort", $va_sort_by, array('id' => "sort"), array("value" => $ps_sort)) : '');
$this->view->setVar('sortControl', $vs_sort_by_select ? _t('Sort with %1', $vs_sort_by_select) : '');
$this->view->setVar('sort', $ps_sort);
$this->view->setVar('sort_direction', $ps_sort_direction);
$va_lists = array();
$va_res_list = array();
$o_browse->execute(array('checkAccess' => $this->opa_access_values));
$qr_res = $o_browse->getResults(array('sort' => $va_sort_by[$ps_sort], 'sort_direction' => $ps_sort_direction));
while ($qr_res->nextHit()) {
$vs_key = $qr_res->getWithTemplate($vs_segment_by);
$va_lists[$vs_key][] = $va_res_list[] = $qr_res->getPrimaryKey();
}
foreach ($va_lists as $vs_key => $va_ids) {
$va_lists[$vs_key] = caMakeSearchResult($vs_table, $va_ids);
//.........这里部分代码省略.........
示例13: individuals
<?php
MetaTagManager::setWindowTitle($this->request->config->get("app_display_name") . ": Performance Assessment & Certification Guidelines");
?>
<div class="container blueBox">
<div class="row">
<div class="col-sm-12">
<p>
Assessment and certification of PA professionals helps ensure that those responsible for protecting valuable resources are competently performing their jobs. Built upon clear competence standards and guidelines, certification programs can provide feedback to individuals (and their employers) on their performance while highlighting opportunities for continuing professional development. Certification works together with the Body of Knowledge and Competence Standards to provide a consistent approach to developing a professional PA workforce.
</p>
</div>
</div>
</div>
<div class="container containerTextPadding">
<div class="row">
<div class="col-sm-12">
<p>
The IUCN WCPA is committed to assisting national or regional bodies in developing competence assessment and certification programs by providing:
</p>
</div><!--end col-sm-12-->
</div>
<div class="row">
<div class="col-sm-6">
<p>
1. <strong>Guidelines</strong> documenting the process for establishing a certification program including key elements and factors for success. These guidelines are best suited for those that want to design their own competence-based certification systems, but who wish to align their programs with the IUCN to be consistent with the international community and potentially receive IUCN endorsement.
</p>
</div><!--end col-sm-6-->
<div class="col-sm-6">
<p>
2. A <strong>model certification program</strong> providing an example of what a full certification program could look like and how the competences should be organized into a certification program with assessment instruments.
</p>
示例14:
<?php
MetaTagManager::setWindowTitle($this->request->config->get("app_display_name") . ": Supporting Initiatives");
?>
<div class="container containerTextPadding">
<div class="row">
<div class="col-sm-6">
<p>
Mentorship among PA professionals helps strengthen the management of protected areas by providing access to experienced conservation professionals. These mentors work in a voluntary capacity to transfer their knowledge, experience, and proven methodologies to improve the competency of others. Mentorship works together with the Body of Knowledge, Assessment and Certification, and Competence Standards to provide a consistent approach to developing a professional PA workforce.
</p>
</div>
<div class="col-sm-6 col-md-5">
<p>
This site provides access to an IUCN WCPA sponsored program provided by <a href="http://www.globalparks.org" target="_blank" class="underline">Global Parks</a> which matches mentors with those requesting mentorship.
</p>
<p>
<ul>
<li>If you are interested in being a mentor, please review the qualifications and submit your application <a href="https://docs.google.com/forms/d/1iOKVn_uVkQ0MHMnrc549TEvuFzT9yO3b2r3TH6C0xbM/viewform?usp=send_form" target="_blank">here</a>.</li>
<li>If you are interested in obtaining a mentor, please submit your application <a href="https://docs.google.com/forms/d/1xv-ly3eFTgzuYnyLCmkZYK2yONLwiyfTlJCQlsxWPIM/viewform?usp=send_form" target="_blank">here</a>. </li>
</ul>
</p>
</div>
</div>
</div>
示例15: setDetail
function setDetail()
{
if (!$this->request->isLoggedIn()) {
$this->response->setRedirect(caNavUrl($this->request, '', 'LoginReg', 'loginForm'));
return;
}
AssetLoadManager::register("mediaViewer");
$ps_view = $this->request->getParameter('view', pString);
if (!in_array($ps_view, array('thumbnail', 'timeline', 'timelineData', 'pdf'))) {
$ps_view = 'thumbnail';
}
$this->view->setVar('view', $ps_view);
$this->view->setVar('views', $this->opo_config->getAssoc("views"));
if (!($t_set = $this->_getSet(__CA_SET_READ_ACCESS__))) {
$this->Index();
}
$va_set_items = caExtractValuesByUserLocale($t_set->getItems(array("user_id" => $this->request->getUserID(), "thumbnailVersions" => array("medium"), "checkAccess" => $this->opa_access_values)));
$this->view->setVar("set", $t_set);
$this->view->setVar("set_items", $va_set_items);
$va_comments = $t_set->getComments();
$this->view->setVar("comments", $va_comments);
$o_context = new ResultContext($this->request, 'ca_objects', 'sets');
$o_context->setResultList($va_set_ids = $t_set->getItems(array('idsOnly' => true)));
$o_context->saveContext();
$o_context->setAsLastFind();
MetaTagManager::setWindowTitle($this->request->config->get("app_display_name") . ": " . _t("Lightbox") . ": " . $t_set->getLabelForDisplay());
switch ($ps_view) {
case 'pdf':
$qr_res = caMakeSearchResult('ca_objects', $va_set_ids);
$this->view->setVar('result', $qr_res);
$this->_genExport($qr_res, '_pdf_checklist', $vs_label = $t_set->get('ca_sets.preferred_labels'), $vs_label);
case 'timelineData':
$this->view->setVar('view', 'timeline');
$this->render("Sets/set_detail_timelineData_json.php");
break;
default:
$this->render("Sets/set_detail_html.php");
break;
}
}