本文整理匯總了PHP中Publication::getProperty方法的典型用法代碼示例。如果您正苦於以下問題:PHP Publication::getProperty方法的具體用法?PHP Publication::getProperty怎麽用?PHP Publication::getProperty使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類Publication
的用法示例。
在下文中一共展示了Publication::getProperty方法的2個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。
示例1: Alias
if ($errorStr != "") {
camp_html_display_error($errorStr, null, true);
}
if (!isset($_SERVER['SERVER_PORT']))
{
$_SERVER['SERVER_PORT'] = 80;
}
$scheme = $_SERVER['SERVER_PORT'] == 443 ? 'https://' : 'http://';
$siteAlias = new Alias($publicationObj->getDefaultAliasId());
$websiteURL = $scheme.$siteAlias->getName();
$accessParams = "LoginUserId=" . $g_user->getUserId() . "&LoginUserKey=" . $g_user->getKeyId()
. "&AdminAccess=all";
$urlType = $publicationObj->getProperty('IdURLType');
if ($urlType == 1) {
$templateObj = new Template($templateId);
$url = "$websiteURL" . $Campsite['SUBDIR'] . "/tpl/" . $templateObj->getName()
. "?IdLanguage=$Language&IdPublication=$Pub&NrIssue=$Issue&$accessParams";
} else {
$url = "$websiteURL" . $Campsite['SUBDIR'] . '/' . $languageObj->getCode()
. "/" . $issueObj->getUrlName() . "?$accessParams";
}
$selectedLanguage = (int)CampRequest::GetVar('Language');
$url .= "&previewLang=$selectedLanguage";
if ($g_user->hasPermission("ManageTempl") || $g_user->hasPermission("DeleteTempl")) {
// Show dual-pane view for those with template management priviledges
?>
示例2: GetInvalidURLTemplate
public static function GetInvalidURLTemplate($p_publicationId)
{
$pub = new Publication($p_publicationId);
return $pub->getProperty('url_error_tpl_id');
} // fn GetInvalidURLTemplate