// Add Link->getAdminLink()

git-svn-id: http://dev.prestashop.com/svn/v1/branches/1.5.x@8839 b9a71923-0436-4b27-9f14-aed3839534dd
This commit is contained in:
rMalie
2011-09-28 09:53:30 +00:00
parent 089a31f32c
commit 7281de8839
+14
View File
@@ -271,6 +271,20 @@ class LinkCore
return $url.Dispatcher::getInstance()->createUrl('module', $params, $this->allow);
}
/**
* Create a link for a backoffice controller
*
* @param unknown_type $controller
* @param unknown_type $params
*/
public function getAdminLink($controller, array $params = array())
{
$url = _PS_BASE_URL_.__PS_BASE_URI__;
$params['token'] = Tools::getAdminTokenLite($controller);
return $url.Dispatcher::getInstance()->createUrl('module', $params, $this->allow);
}
/**
* Returns a link to a product image for display
* Note: the new image filesystem stores product images in subdirectories of img/p/