本文整理汇总了PHP中FrontController::canonicalRedirection方法的典型用法代码示例。如果您正苦于以下问题:PHP FrontController::canonicalRedirection方法的具体用法?PHP FrontController::canonicalRedirection怎么用?PHP FrontController::canonicalRedirection使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类FrontController
的用法示例。
在下文中一共展示了FrontController::canonicalRedirection方法的11个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: canonicalRedirection
public function canonicalRedirection()
{
if (Configuration::get('PS_CANONICAL_REDIRECT') && strtoupper($_SERVER['REQUEST_METHOD']) == 'GET' && !Tools::getValue('ajax') && !Tools::getIsset('ps_mobile_site') && !Tools::getIsset('add') && !Tools::getIsset('update') && !Tools::getIsset('delete')) {
$this->php_self = Configuration::get('PS_ORDER_PROCESS_TYPE') == 1 ? 'order-opc.php' : 'order.php';
parent::canonicalRedirection();
}
}
示例2: canonicalRedirection
public function canonicalRedirection($canonicalURL = '')
{
if (Validate::isLoadedObject($this->cms) && ($canonicalURL = $this->context->link->getCMSLink($this->cms, $this->cms->link_rewrite, $this->ssl))) {
parent::canonicalRedirection($canonicalURL);
} elseif (Validate::isLoadedObject($this->cms_category) && ($canonicalURL = $this->context->link->getCMSCategoryLink($this->cms_category))) {
parent::canonicalRedirection($canonicalURL);
}
}
示例3: canonicalRedirection
public function canonicalRedirection($canonical_url = '')
{
if (Tools::getValue('live_edit')) {
return;
}
if (Validate::isLoadedObject($this->product)) {
parent::canonicalRedirection($this->context->link->getProductLink($this->product));
}
}
示例4: canonicalRedirection
public function canonicalRedirection($canonicalURL = '')
{
if (Tools::getValue('live_edit')) {
return;
}
if (Validate::isLoadedObject($this->manufacturer)) {
parent::canonicalRedirection($this->context->link->getManufacturerLink($this->manufacturer));
}
}
示例5: canonicalRedirection
public function canonicalRedirection($canonicalURL = '')
{
if (!Validate::isLoadedObject($this->category) || !$this->category->inShop() || !$this->category->isAssociatedToShop()) {
$this->redirect_after = '404';
$this->redirect();
}
if (!Tools::getValue('noredirect') && Validate::isLoadedObject($this->category)) {
parent::canonicalRedirection($this->context->link->getCategoryLink($this->category));
}
}
示例6: canonicalRedirection
/**
* Redirects to canonical or "Not Found" URL
*
* @param string $canonical_url
*/
public function canonicalRedirection($canonical_url = '')
{
if (Tools::getValue('live_edit')) {
return;
}
if (!Validate::isLoadedObject($this->category) || !$this->category->inShop() || !$this->category->isAssociatedToShop() || in_array($this->category->id, array(Configuration::get('PS_HOME_CATEGORY'), Configuration::get('PS_ROOT_CATEGORY')))) {
$this->redirect_after = '404';
$this->redirect();
}
if (!Tools::getValue('noredirect') && Validate::isLoadedObject($this->category)) {
parent::canonicalRedirection($this->context->link->getCategoryLink($this->category));
}
}
示例7: canonicalRedirection
public function canonicalRedirection($canonicalURL = '')
{
if (Tools::getValue('live_edit')) {
return;
}
if (Validate::isLoadedObject($this->supplier)) {
if (Validate::isLoadedObject($this->category)) {
parent::canonicalRedirection($this->context->link->getSupplierProductLinkByCategory($this->supplier->id, $this->category->id));
} else {
parent::canonicalRedirection($this->context->link->getSupplierLink($this->supplier));
}
}
}
示例8: canonicalRedirection
public function canonicalRedirection($canonicalURL = '')
{
if (Tools::getValue('live_edit')) {
return;
}
if (Validate::isLoadedObject($this->cms) && ($canonicalURL = $this->context->link->getCMSLink($this->cms))) {
parent::canonicalRedirection($canonicalURL);
} else {
if (Validate::isLoadedObject($this->cms_category) && ($canonicalURL = $this->context->link->getCMSCategoryLink($this->cms_category))) {
parent::canonicalRedirection($canonicalURL);
}
}
}
示例9: canonicalRedirection
public function canonicalRedirection($canonical_url = '')
{
if (Validate::isLoadedObject($this->product)) {
parent::canonicalRedirection($this->context->link->getProductLink($this->product));
}
}
示例10: canonicalRedirection
protected function canonicalRedirection($canonical_url = '')
{
parent::canonicalRedirection();
}
示例11: canonicalRedirection
public function canonicalRedirection($canonicalURL = '')
{
if (Validate::isLoadedObject($this->manufacturer)) {
parent::canonicalRedirection($this->context->link->getManufacturerLink($this->manufacturer));
}
}