本文整理汇总了PHP中PageTheme类的典型用法代码示例。如果您正苦于以下问题:PHP PageTheme类的具体用法?PHP PageTheme怎么用?PHP PageTheme使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
在下文中一共展示了PageTheme类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: run
public function run() {
$db = Loader::db();
Loader::model('single_page');
Cache::disableLocalCache();
// we backup the custom styles table
$this->backupCustomStylesTables();
// upgrade blocks that differ between versions
$this->updateBlocks();
// Migrate data from the custom styles tables to the new approach
$this->migrateCustomStyleData();
$this->setupSiteSearchIndexing();
$this->installTaskPermissions();
$this->updateDashboard();
// add the dark chocolate theme
$pt = PageTheme::getByHandle('dark_chocolate');
if (!is_object($pt)) {
$chocolate = PageTheme::add('dark_chocolate');
}
Cache::enableLocalCache();
}
示例2: activate_files
public function activate_files($ptID)
{
try {
Loader::model("collection_types");
$pt = PageTheme::getByID($ptID);
$txt = Loader::helper('text');
if (!is_array($this->post('pageTypes'))) {
throw new Exception(t("You must specify at least one template to make into a page type."));
}
$pkg = false;
$pkgHandle = $pt->getPackageHandle();
if ($pkgHandle) {
$pkg = Package::getByHandle($pkgHandle);
}
foreach ($this->post('pageTypes') as $ptHandle) {
$data['ctName'] = $txt->unhandle($ptHandle);
$data['ctHandle'] = $ptHandle;
$ct = CollectionType::add($data, $pkg);
}
$this->set('message', t('Files in the theme were activated successfully.'));
} catch (Exception $e) {
$this->set('error', $e);
}
$this->view($ptID);
}
示例3: run
public function run()
{
// Since we added the origfilename column in 5.0.0b1 we need to populate it
Loader::block('library_file');
$bl = new LibraryFileBlockController();
$bl->populateOriginalFilenames();
// install the new block types made available
BlockType::installBlockType('flash_content');
BlockType::installBlockType('guestbook');
BlockType::installBlockType('slideshow');
BlockType::installBlockType('search');
BlockType::installBlockType('google_map');
BlockType::installBlockType('video');
BlockType::installBlockType('rss_displayer');
BlockType::installBlockType('youtube');
BlockType::installBlockType('survey');
// rename external form
$bt = BlockType::getByHandle('custom_form');
$db = Loader::db();
$tables = $db->MetaTables('TABLES');
if (isset($tables['btCustomForm']) && !isset($tables['btExternalForm'])) {
$db->Execute("alter table btCustomForm rename btExternalForm");
}
if (is_object($bt)) {
BlockType::installBlockType('external_form', $bt->getBlockTypeID());
}
// add new theme
$th = PageTheme::getByHandle('greensalad');
if (!is_object($th)) {
PageTheme::add('greensalad');
}
}
示例4: reset
public function reset() {
$vt = Loader::helper('validation/token');
if ($vt->validate()) {
$themeID = $this->post('themeID');
$pt = PageTheme::getByID($themeID);
if (is_object($pt)) {
$values = $pt->reset();
$this->redirect('/dashboard/pages/themes/customize', 'view', $themeID, 'reset');
}
}
}
示例5: run
public function run()
{
$this->x = new SimpleXMLElement("<concrete5-cif></concrete5-cif>");
$this->x->addAttribute('version', '1.0');
// First, attribute categories
AttributeKeyCategory::exportList($this->x);
// attribute types
AttributeType::exportList($this->x);
// then block types
BlockTypeList::exportList($this->x);
// now attribute keys (including user)
AttributeKey::exportList($this->x);
// now attribute keys (including user)
AttributeSet::exportList($this->x);
// now theme
PageTheme::exportList($this->x);
// now packages
PackageList::export($this->x);
// permission access entity types
PermissionAccessEntityType::exportList($this->x);
// now task permissions
PermissionKey::exportList($this->x);
// workflow types
WorkflowType::exportList($this->x);
// now jobs
Loader::model('job');
Job::exportList($this->x);
// now single pages
$singlepages = $this->x->addChild("singlepages");
$db = Loader::db();
$r = $db->Execute('select cID from Pages where cFilename is not null and cFilename <> "" and cID not in (select cID from Stacks) order by cID asc');
while ($row = $r->FetchRow()) {
$pc = Page::getByID($row['cID'], 'RECENT');
$pc->export($singlepages);
}
// now page types
CollectionType::exportList($this->x);
// now stacks/global areas
Loader::model('stack/list');
StackList::export($this->x);
// now content pages
$pages = $this->x->addChild("pages");
$db = Loader::db();
$r = $db->Execute('select Pages.cID from Pages left join ComposerDrafts on Pages.cID = ComposerDrafts.cID where ComposerDrafts.cID is null and cIsTemplate = 0 and cFilename is null or cFilename = "" order by cID asc');
while ($row = $r->FetchRow()) {
$pc = Page::getByID($row['cID'], 'RECENT');
$pc->export($pages);
}
Loader::model("system/captcha/library");
SystemCaptchaLibrary::exportList($this->x);
Config::exportList($this->x);
}
示例6: install
public function install($data = array())
{
$pkg = parent::install();
// Set Theme
// check for active themes
$active_theme = PageTheme::getSiteTheme();
// strcmp($active_theme->getThemeHandle(), $themeHandle) == 0
if (is_object($active_theme) && $active_theme->getThemeHandle() !== 'elemental') {
// Theme::setThemeHandle($themeHandle);
// $pt = PageTheme::getByID($pThemeID);
$pt = PageTheme::getByHandle('elemental');
$pt->applyToSite();
}
}
示例7: install
public function install()
{
Loader::model('collection_types');
$pkg = parent::install();
PageTheme::add('casual', $pkg);
$pagetypearray = array(array("left_sidebar", "Left Sidebar"), array("right_sidebar", "Right Sidebar"), array("full", "One Column"), array("three_column", "Three Column Layout"));
foreach ($pagetypearray as $value) {
$pageType = CollectionType::getByHandle($value[0]);
if (!$pageType) {
$pkg = Package::getByHandle('casual');
$newPageType = CollectionType::add(array('ctHandle' => $value[0], 'ctName' => t($value[1])), $pkg);
} else {
$newPageType = $pageType;
}
}
}
示例8: exportAll
public function exportAll()
{
$this->x = $this->getXMLRoot();
// First, attribute categories
AttributeKeyCategory::exportList($this->x);
// attribute types
AttributeType::exportList($this->x);
// then block types
BlockTypeList::exportList($this->x);
// now attribute keys (including user)
AttributeKey::exportList($this->x);
// now attribute keys (including user)
AttributeSet::exportList($this->x);
// now theme
PageTheme::exportList($this->x);
// now packages
PackageList::export($this->x);
// permission access entity types
PermissionAccessEntityType::exportList($this->x);
// now task permissions
PermissionKey::exportList($this->x);
// workflow types
WorkflowType::exportList($this->x);
// now jobs
Loader::model('job');
Job::exportList($this->x);
// now single pages
$singlepages = $this->x->addChild("singlepages");
$db = Loader::db();
$r = $db->Execute('select cID from Pages where cFilename is not null and cFilename <> "" and cID not in (select cID from Stacks) order by cID asc');
while ($row = $r->FetchRow()) {
$pc = Page::getByID($row['cID'], 'RECENT');
$pc->export($singlepages);
}
// now page types
CollectionType::exportList($this->x);
// now stacks/global areas
Loader::model('stack/list');
StackList::export($this->x);
$this->exportPages($this->x);
Loader::model("system/captcha/library");
SystemCaptchaLibrary::exportList($this->x);
Config::exportList($this->x);
}
示例9: install
public function install()
{
Loader::library('mootools/attribute', FRONTEND_DEVELOPER_PACKAGE_HANDLE);
$pkg = parent::install();
Loader::model('single_page');
Loader::model('attribute/categories/user');
Loader::model('attribute/categories/file');
$singlePages = array("/dashboard/mootools" => array('cName' => t('Mootools Plugin Developer'), 'cDescription' => t('Management of mootools plugin')), "/dashboard/mootools/plugin" => array('cName' => t('plugin'), 'cDescription' => t('Management of Mootools Plugin that does import')), "/dashboard/mootools/importer" => array('cName' => t('import'), 'cDescription' => t('Import from repository')));
foreach ($singlePages as $key => $page) {
$collection = SinglePage::add($key, $pkg);
if (!empty($collection)) {
$collection->update($page);
}
}
//The name of the user of github is added to the attribute.
$values = array("akHandle" => MOOTOOLS_GITHUB_USER, "akName" => t("Name of user of github"), "akIsSearchable" => true, "akIsSearchableIndexed" => true, "akIsAutoCreated" => true, "akIsEditable" => true);
$key = UserAttributeKey::add("text", $values, $pkg);
$fileAttributes = array(array("type" => "boolean", "values" => array("akHandle" => MOOTOOLS_PLUGIN, "akName" => t("This file is a plugin of Mootools"), "akIsSearchable" => true, "akIsSearchableIndexed" => true, "akIsAutoCreated" => true, "akIsEditable" => true)), array("type" => "text", "values" => array("akHandle" => MOOTOOLS_COMPONENT_NAME, "akName" => t("Component name of Mootools"), "akIsSearchable" => true, "akIsSearchableIndexed" => true, "akIsAutoCreated" => true, "akIsEditable" => true)), array("type" => "text", "values" => array("akHandle" => MOOTOOLS_PLUGIN_LICENSE, "akName" => t("License of Mootools plugin"), "akIsSearchable" => true, "akIsSearchableIndexed" => true, "akIsAutoCreated" => true, "akIsEditable" => true)), array("type" => "text", "values" => array("akHandle" => MOOTOOLS_PLUGIN_AUTHORS, "akName" => t("Authors of Mootools plugin"), "akIsSearchable" => true, "akIsSearchableIndexed" => true, "akIsAutoCreated" => true, "akIsEditable" => true)), array("type" => "select", "values" => array("akHandle" => MOOTOOLS_PLUGIN_DEPENDENCES, "akName" => t("Dependence of Mootools plugin"), "akIsSearchable" => true, "akIsSearchableIndexed" => true, "akIsAutoCreated" => true, "akIsEditable" => true)), array("type" => "number", "values" => array("akHandle" => MOOTOOLS_PLUGIN_DISPLAY_ORDER, "akName" => t("The order of display of Mootools plugin"), "akIsSearchable" => true, "akIsSearchableIndexed" => true, "akIsAutoCreated" => true, "akIsEditable" => true)));
$attributesKeys = array();
foreach ($fileAttributes as $key => $attr) {
$type = $attr["type"];
$values = $attr["values"];
$handle = $values["akHandle"];
$attributesKeys[$handle] = FileAttributeKey::add($type, $values, $pkg);
}
if (!empty($attributesKeys[MOOTOOLS_PLUGIN_DEPENDENCES])) {
$key = $attributesKeys[MOOTOOLS_PLUGIN_DEPENDENCES];
$db = Loader::db();
$db->Replace('atSelectSettings', array('akID' => $key->getAttributeKeyID(), 'akSelectAllowMultipleValues' => true), array('akID'), true);
}
BlockType::installBlockTypeFromPackage("mootools_plugin_build_form", $pkg);
BlockType::installBlockTypeFromPackage("github_tags", $pkg);
BlockType::installBlockTypeFromPackage("github_issues", $pkg);
BlockType::installBlockTypeFromPackage("github_repository", $pkg);
PageTheme::add('small_project', $pkg);
}
示例10: testCustomizableStyleSheetObjects
public function testCustomizableStyleSheetObjects()
{
$defaults = dirname(__FILE__) . '/fixtures/elemental.less';
$list = \Concrete\Core\StyleCustomizer\Style\ValueList::loadFromLessFile($defaults);
$env = Environment::get();
$pt = new PageTheme();
$pt->setThemeHandle('elemental');
$pt->setThemeDirectory($env->getPath(DIRNAME_THEMES . '/elemental'));
$pt->setThemeURL($env->getURL(DIRNAME_THEMES . '/elmental'));
$sheets = $pt->getThemeCustomizableStyleSheets();
$this->assertTrue(count($sheets) == 1);
$this->assertTrue($sheets[0] instanceof \Concrete\Core\StyleCustomizer\Stylesheet);
$css = $sheets[0]->getCss();
$this->assertTrue(strpos($css, "background-image: url('/path/to/server/concrete/themes/elemental/images/background-slider-default.png')") !== false);
$sheets[0]->setValueList($list);
$css = $sheets[0]->getCss();
$this->assertTrue(strpos($css, "background-image: url('/path/to/server/concrete/themes/elemental/images/testingit.jpg')") !== false);
$this->assertTrue(strpos($css, 'font-family: "Testing Font Family"') !== false);
$sheet = $pt->getStylesheetObject('typography.less');
$sheet->setValueList($list);
$this->assertTrue($sheet->getOutputPath() == DIR_BASE . '/application/files/cache/css/elemental/typography.css');
$this->assertTrue($sheet->getOutputRelativePath() == DIR_REL . '/application/files/cache/css/elemental/typography.css');
}
示例11:
}
if (!isset($editor_selector)) {
$editor_selector = 'ccm-advanced-editor';
}
if (isset($editor_height)) {
$textEditorHeight = $editor_height;
}
if (isset($editor_width)) {
$textEditorWidth = $editor_width;
}
if (!isset($editor_mode)) {
$txtEditorMode = Config::get('CONTENTS_TXT_EDITOR_MODE');
} else {
$txtEditorMode = $editor_mode;
}
$theme = PageTheme::getSiteTheme();
?>
<script type="text/javascript">
var validElementsHtml5 =
"@[accesskey|draggable|style|class|hidden|tabindex" +
"|contenteditable|id|title|contextmenu|lang|dir<ltr?rtl|spellcheck" +
"|onabort|onerror|onmousewheel|onblur|onfocus|onpause|oncanplay|onformchange|onplay" +
"|oncanplaythrough|onforminput|onplaying|onchange|oninput|onprogress|onclick|oninvalid" +
"|onratechange|oncontextmenu|onkeydown|onreadystatechange|ondblclick|onkeypress|onscroll" +
"|ondrag|onkeyup|onseeked|ondragend|onload|onseeking|ondragenter|onloadeddata|onselect" +
"|ondragleave|onloadedmetadata|onshow|ondragover|onloadstart|onstalled|ondragstart" +
"|onmousedown|onsubmit|ondrop|onmousemove|onsuspend|ondurationmouseout|ontimeupdate" +
"|onemptied|onmouseover|onvolumechange|onended|onmouseup|onwaiting]," +
"a[target<_blank?_self?_top?_parent|ping|media|href|hreflang|type" +
"|rel<alternate?archives?author?bookmark?external?feed?first?help?index?last?license?" +
"next?nofollow?noreferrer?prev?search?sidebar?tag?up" +
示例12: activate_confirm
public function activate_confirm($ptID, $token)
{
$l = PageTheme::getByID($ptID);
$val = Loader::helper('validation/error');
$valt = Loader::helper('validation/token');
if (!$valt->validate('activate', $token)) {
$val->add($valt->getErrorMessage());
$this->set('error', $val);
} else {
if (!is_object($l)) {
$val->add('Invalid Theme');
$this->set('error', $val);
} else {
$l->applyToSite();
$this->set('message', t('Theme activated'));
}
}
$this->view();
}
示例13: getSiteTheme
public function getSiteTheme() {
$c = Page::getByID(HOME_CID);
return PageTheme::getByID($c->getCollectionThemeID());
}
示例14: run
public function run()
{
if (!Config::get('SITE_INSTALLED_APP_VERSION')) {
Config::save('SITE_INSTALLED_APP_VERSION', Config::get('SITE_APP_VERSION'));
}
BlockTypeList::resetBlockTypeDisplayOrder();
$th = PageTheme::getByHandle('greek_yogurt');
if (!is_object($th)) {
PageTheme::add('greek_yogurt');
}
$bt = BlockType::getByHandle('core_scrapbook_display');
if (is_object($bt)) {
$bt->refresh();
}
$bt = BlockType::getByHandle('search');
if (is_object($bt)) {
$bt->refresh();
}
$sp = Page::getByPath('/dashboard/users/group_sets');
if ($sp->isError()) {
$d11 = SinglePage::add('/dashboard/users/group_sets');
$d11->update(array('cName' => t('Group Sets')));
}
$sp = Page::getByPath('/dashboard/system/seo/bulk_seo_tool');
if ($sp->isError()) {
$d1a = SinglePage::add('/dashboard/system/seo/bulk_seo_tool');
$d1a->update(array('cName' => t('Bulk SEO Updater')));
}
$sp = Page::getByPath('/dashboard/system/permissions/users');
if ($sp->isError()) {
$d1a = SinglePage::add('/dashboard/system/permissions/users');
$d1a->update(array('cName' => t('User Permissions')));
}
$sp = Page::getByPath('/dashboard/blocks/permissions');
if ($sp->isError()) {
$d1a = SinglePage::add('/dashboard/blocks/permissions');
$d1a->update(array('cName' => t('Block & Stack Permissions')));
}
$sp = Page::getByPath('/dashboard/system/permissions/advanced');
if ($sp->isError()) {
$d1b = SinglePage::add('/dashboard/system/permissions/advanced');
$d1b->update(array('cName' => t('Advanced Permissions')));
}
$sp = Page::getByPath('/dashboard/workflow');
if ($sp->isError()) {
$d1a = SinglePage::add('/dashboard/workflow');
$d1a->update(array('cName' => t('Workflow')));
}
$sp = Page::getByPath('/dashboard/workflow/list');
if ($sp->isError()) {
$d1a = SinglePage::add('/dashboard/workflow/list');
}
$sp = Page::getByPath('/dashboard/workflow/me');
if ($sp->isError()) {
$d1a = SinglePage::add('/dashboard/workflow/me');
$d1a->update(array('cName' => t('Waiting for Me')));
}
$sp = Page::getByPath('/dashboard/system/environment/proxy');
if ($sp->isError()) {
$d1a = SinglePage::add('/dashboard/system/environment/proxy');
$d1a->update(array('cName' => t('Proxy Server')));
}
// update meta keywords
$pageKeywords = array('/dashboard/composer' => t('blog, blogging'), '/dashboard/composer/write' => t('new blog, write blog, blogging'), '/dashboard/composer/drafts' => t('blog drafts, composer'), '/dashboard/sitemap' => t('pages, add page, delete page, copy, move, alias'), '/dashboard/sitemap/full' => t('pages, add page, delete page, copy, move, alias'), '/dashboard/sitemap/explore' => t('pages, add page, delete page, copy, move, alias, bulk'), '/dashboard/sitemap/search' => t('find page, search page, search, find, pages, sitemap'), '/dashboard/files/search' => t('add file, delete file, copy, move, alias, resize, crop, rename, images, title, attribute'), '/dashboard/files/attributes' => t('file, file attributes, title, attribute, description, rename'), '/dashboard/files/sets' => t('files, category, categories'), '/dashboard/files/add_set' => t('new file set'), '/dashboard/users' => t('users, groups, people, find, delete user, remove user, change password, password'), '/dashboard/users/search' => t('find, search, people, delete user, remove user, change password, password'), '/dashboard/users/groups' => t('user, group, people, permissions, access, expire'), '/dashboard/users/attributes' => t('user attributes, user data, gather data, registration data'), '/dashboard/users/add' => t('new user, create'), '/dashboard/users/add_group' => t('new user group, new group, group, create'), '/dashboard/users/group_sets' => t('group set'), '/dashboard/reports' => t('forms, log, error, email, mysql, exception, survey'), '/dashboard/reports/statistics' => t('hits, pageviews, visitors, activity'), '/dashboard/reports/forms' => t('forms, questions, response, data'), '/dashboard/reports/surveys' => t('questions, quiz, response'), '/dashboard/reports/logs' => t('forms, log, error, email, mysql, exception, survey, history'), '/dashboard/pages/themes' => t('new theme, theme, active theme, change theme, template, css'), '/dashboard/pages/themes/add' => t('theme'), '/dashboard/pages/themes/inspect' => t('page types'), '/dashboard/pages/themes/customize' => t('custom theme, change theme, custom css, css'), '/dashboard/pages/types' => t('page type defaults, global block, global area, starter, template'), '/dashboard/pages/attributes' => t('page attributes, custom'), '/dashboard/pages/single' => t('single, page, custom, application'), '/dashboard/workflow' => t('add workflow, remove workflow'), '/dashboard/blocks/stacks' => t('stacks, reusable content, scrapbook, copy, paste, paste block, copy block, site name, logo'), '/dashboard/blocks/stacks/list' => t('edit stacks, view stacks, all stacks'), '/dashboard/blocks/types' => t('block, refresh, custom'), '/dashboard/extend' => t('add-on, addon, add on, package, applications, ecommerce, discussions, forums, themes, templates, blocks'), '/dashboard/extend/install' => t('add-on, addon, ecommerce, install, discussions, forums, themes, templates, blocks'), '/dashboard/extend/update' => t('update, upgrade'), '/dashboard/extend/connect' => t('concrete5.org, my account, marketplace'), '/dashboard/extend/themes' => t('buy theme, new theme, marketplace, template'), '/dashboard/extend/add-ons' => t('buy addon, buy add on, buy add-on, purchase addon, purchase add on, purchase add-on, find addon, new addon, marketplace'), '/dashboard/system' => t('dashboard, configuration'), '/dashboard/system/basics/site_name' => t('website name, title'), '/dashboard/system/basics/icons' => t('logo, favicon, iphone, icon, bookmark'), '/dashboard/system/basics/editor' => t('tinymce, content block, fonts, editor, content, overlay'), '/dashboard/system/basics/multilingual' => t('translate, translation, internationalization, multilingual'), '/dashboard/system/basics/timezone' => t('timezone, profile, locale'), '/dashboard/system/basics/interface' => t('interface, quick nav, dashboard background, background image'), '/dashboard/system/seo/urls' => t('vanity, pretty url, seo, pageview, view'), '/dashboard/system/seo/bulk_seo_tool' => t('bulk, seo, change keywords, engine, optimization, search'), '/dashboard/system/seo/tracking_codes' => t('traffic, statistics, google analytics, quant, pageviews, hits'), '/dashboard/system/seo/statistics' => t('turn off statistics, tracking, statistics, pageviews, hits'), '/dashboard/system/seo/search_index' => t('configure search, site search, search option'), '/dashboard/system/optimization/cache' => t('cache option, change cache, override, turn on cache, turn off cache, no cache, page cache, caching'), '/dashboard/system/optimization/clear_cache' => t('cache option, turn off cache, no cache, page cache, caching'), '/dashboard/system/optimization/jobs' => t('index search, reindex search, build sitemap, sitemap.xml, clear old versions, page versions, remove old'), '/dashboard/system/permissions/site' => t('editors, hide site, offline, private, public, access'), '/dashboard/system/permissions/files' => t('file options, file manager, upload, modify'), '/dashboard/system/permissions/file_types' => t('security, files, media, extension, manager, upload'), '/dashboard/system/permissions/tasks' => t('security, actions, administrator, admin, package, marketplace, search'), '/dashboard/system/permissions/ip_blacklist' => t('security, lock ip, lock out, block ip, address, restrict, access'), '/dashboard/system/permissions/captcha' => t('security, registration'), '/dashboard/system/permissions/antispam' => t('antispam, block spam, security'), '/dashboard/system/permissions/maintenance_mode' => t('lock site, under construction, hide, hidden'), '/dashboard/system/registration/postlogin' => t('profile, login, redirect, specific, dashboard, administrators'), '/dashboard/system/registration/profiles' => t('member profile, member page, community, forums, social, avatar'), '/dashboard/system/registration/public_registration' => t('signup, new user, community'), '/dashboard/system/mail' => t('smtp, mail settings'), '/dashboard/system/mail/method' => t('email server, mail settings, mail configuration, external, internal'), '/dashboard/system/mail/importers' => t('email server, mail settings, mail configuration, private message, message system, import, email, message'), '/dashboard/system/attributes' => t('attribute configuration'), '/dashboard/system/attributes/sets' => t('attributes, sets'), '/dashboard/system/attributes/types' => t('attributes, types'), '/dashboard/system/environment/info' => t('overrides, system info, debug, support, help'), '/dashboard/system/environment/debug' => t('errors, exceptions, develop, support, help'), '/dashboard/system/environment/logging' => t('email, logging, logs, smtp, pop, errors, mysql, log'), '/dashboard/system/environment/file_storage_locations' => t('security, alternate storage, hide files'), '/dashboard/system/environment/proxy' => t('network, proxy server'), '/dashboard/system/backup_restore' => t('export, backup, database, sql, mysql, encryption, restore'), '/dashboard/system/backup_restore/update' => t('upgrade, new version, update'), '/dashboard/system/backup_restore/database' => t('export, database, xml, starting, points, schema, refresh, custom, tables'), '/dashboard/system/seo/search_index' => t('configure search, site search, search option'), '/dashboard/system/optimization/cache' => t('cache option, change cache, override, turn on cache, turn off cache, no cache, page cache, caching'));
foreach ($pageKeywords as $page => $keywords) {
$p = Page::getByPath($page, 'ACTIVE');
$ak = CollectionAttributeKey::getByHandle('meta_keywords');
if (is_object($p) && !$p->isError() && $ak instanceof AttributeKey) {
$p->setAttribute('meta_keywords', $keywords);
}
}
// install the permissions from permissions.xml
$this->installPermissionsAndWorkflow();
$this->addGlobalBlockPermissions();
$this->migratePagePermissions();
$this->migratePagePermissionPageTypes();
$this->migrateAreaPermissions();
$this->migrateAreaPermissionBlockTypes();
$this->migrateBlockPermissions();
$this->migrateFileSetPermissions();
$this->migrateAddFilePermissions();
$this->migrateFilePermissions();
$this->migrateTaskPermissions();
$this->migrateThemes();
$this->migratePageTypes();
$this->setupDashboardIcons();
}
示例15: function
'dataType': 'json',
'success': function(r) {
$('input[name=autosave]').val('0');
ccm_composerLastSaveTime = new Date();
$("#composer-save-status").html('<?php echo t("Page saved at ")?>' + r.time);
$(".ccm-composer-hide-on-approved").show();
if (callback) {
callback();
}
}
});
}
ccm_composerLaunchPreview = function() {
jQuery.fn.dialog.showLoader();
<?php $t = PageTheme::getSiteTheme(); ?>
ccm_composerDoAutoSave(function() {
ccm_previewInternalTheme(<?php echo $entry->getCollectionID()?>, <?php echo $t->getThemeID()?>, '<?php echo addslashes(str_replace(array("\r","\n","\n"),'',$t->getThemeName()))?>');
});
}
ccm_composerSelectParentPage = function(cID) {
$("input[name=cPublishParentID]").val(cID);
$(".ccm-composer-hide-on-no-target").show();
$("#ccm-composer-publish-location").load('<?php echo $this->action("select_publish_target")?>', {'entryID': <?php echo $entry->getCollectionID()?>, 'cPublishParentID': cID});
jQuery.fn.dialog.closeTop();
}
ccm_composerSelectParentPageAndSubmit = function(cID) {
$("input[name=cPublishParentID]").val(cID);