本文整理匯總了PHP中BackendModel::getURL方法的典型用法代碼示例。如果您正苦於以下問題:PHP BackendModel::getURL方法的具體用法?PHP BackendModel::getURL怎麽用?PHP BackendModel::getURL使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類BackendModel
的用法示例。
在下文中一共展示了BackendModel::getURL方法的4個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。
示例1: parse
/**
* Parse the page
*/
protected function parse()
{
parent::parse();
// get url
$url = BackendModel::getURLForBlock($this->URL->getModule(), 'detail');
$url404 = BackendModel::getURL(404);
// parse additional variables
if ($url404 != $url) {
$this->tpl->assign('detailURL', SITE_URL . $url);
}
}
示例2: parse
/**
* Parse the form
*/
protected function parse()
{
parent::parse();
// get url
$url = BackendModel::getURLForBlock($this->URL->getModule(), 'detail');
$url404 = BackendModel::getURL(404);
if ($url404 != $url) {
$this->tpl->assign('detailURL', SITE_URL . $url);
}
// assign the active record and additional variables
$this->tpl->assign('item', $this->record);
$this->tpl->assign('feedback', $this->feedback);
}
示例3: parse
/**
* Parse the form
*/
protected function parse()
{
parent::parse();
// get url
$url = BackendModel::getURLForBlock($this->URL->getModule(), 'detail');
$url404 = BackendModel::getURL(404);
// parse additional variables
if ($url404 != $url) {
$this->tpl->assign('detailURL', SITE_URL . $url);
}
// fetch proper slug
$this->record['url'] = $this->meta->getURL();
// assign the active record and additional variables
$this->tpl->assign('item', $this->record);
$this->tpl->assign('status', BL::lbl(SpoonFilter::ucfirst($this->record['status'])));
// assign revisions-datagrid
$this->tpl->assign('revisions', $this->dgRevisions->getNumResults() != 0 ? $this->dgRevisions->getContent() : false);
$this->tpl->assign('drafts', $this->dgDrafts->getNumResults() != 0 ? $this->dgDrafts->getContent() : false);
$this->tpl->assign('imageIsAllowed', $this->imageIsAllowed);
// assign category
if ($this->categoryId !== null) {
$this->tpl->assign('categoryId', $this->categoryId);
}
}
示例4: loadFormForStep4
/**
* Load the form for step 4
*
* @return void
*/
private function loadFormForStep4()
{
// check if we have to redirect back to step 3 (HTML content is not set)
if (empty($this->record['content_html'])) {
$this->redirect(BackendModel::createURLForAction('edit') . '&id=' . $this->id . '&step=3&error=complete-step-3');
}
// get preview URL
$previewURL = BackendMailmotorModel::getMailingPreviewURL($this->record['id']);
// check if the mailmotor is linked
if (BackendModel::getURLForBlock($this->getModule(), 'detail') == BackendModel::getURL(404)) {
$previewURL = false;
}
// parse the preview URL
$this->tpl->assign('previewURL', $previewURL);
// create form
$this->frm = new BackendForm('step4');
// subject
$this->frm->addText('email');
$this->frm->addDate('send_on_date', $this->record['send_on']);
$this->frm->addTime('send_on_time', SpoonDate::getDate('H:i', $this->record['send_on']));
// show the form
$this->tpl->assign('step4', true);
}