ShopUrls
Helper to get configured URLs to be used in the webshop.
Generated URLs consider configured categories for several webshop pages and settings for trailing slashes or item URL patterns.
Namespace
IO\Extensions\Constants
Type | Name | Description |
---|---|---|
|
||
|
Define if a trailing slash should be appended to URLS or not. Consider this option to avoid unnecessary 301 redirects. |
|
|
Suffix to append to URLs containing a trailing slash if required. |
|
|
Indicate if the language should be included in URLs. This is false if the current language equals the default language of the webstore. Otherwise the language should be included in the URLs to be detected correctly. |
|
|
Relative URL of the basket view. |
|
|
Relative URL of the cancellation form view. |
|
|
Relative URL of the cancellation rights view. |
|
|
Relative URL of the checkout view. |
|
|
Relative URL of the order confirmation view of the most recent order. Use orderConfirmation() to get the URL for the order confirmation view of a specific order. |
|
|
Relative URL of the contact view. |
|
|
Relative URL of the general terms and conditions view. |
|
|
Relative URL of the home page. |
|
|
Relative URL of the legal disclosure view. |
|
|
Relative URL of the login page. |
|
|
Relative URL of the my-account view. |
|
|
Relative URL of the view displaying the form to reset a password. |
|
|
Relative URL of the privacy policy. |
|
|
Relative URL of the registration form. |
|
|
Relative URL of the item search view. |
|
|
Relative URL of the general terms and conditions view. Deprecated: since 5.0.12. Use $gtc instead. |
|
|
Relative URL of the wish list view. |
|
|
Relative URL of the returns form for the most recent order. Use returns() to get the URL for the returns form for a specific order. |
|
|
Relative URL of the order return confirmation. Deprecated: since 5.0.12. This is not in use anymore since only a success message will be displayed after submitting a return. |
|
|
Relative URL of the form to change a customer’s mail. |
|
|
Relative URL of the form to unsubscribe from a newsletter. |
|
|
Get a preview URL for an order document. Deprecated: since 5.0.12. Not in use anymore. Use orderDocumentPreview() instead. |
|
|
||
|
Methods
public __construct($dispatcher)
Type |
Name |
Description |
|
public returns($orderId, $orderAccessKey = null):string
Get the URL of the return form for a specific order.
Type |
Name |
Description |
|
The id of the order to return items for. |
|
|
Access key to authorize accessing the order. Required for guest accounts. |
public orderPropertyFile($path):string
Get the URL of a file stored in an order property.
Type |
Name |
Description |
|
The path to the file read from the value of the order property. |
public orderDocumentPreview($documentId, $orderId, $orderAccessKey = null):string
Get a preview URL for an order document.
Type |
Name |
Description |
|
Id of the order document to get order. |
|
|
Id of the order the document belongs to. |
|
|
Access key to authorize accessing the order. Required for guest accounts. |
public tracking($orderId):string
Get tracking URL for a specific order id.
Type |
Name |
Description |
|
Id of the order to get the tracking URL for. |
public orderConfirmation($orderId):string
Get the URL of the order confirmation page for a specific order id.
Type |
Name |
Description |
|
Id of the order to get the confirmation URL for. |
public equals($urlA, $urlB):bool
Check if two routes are equal but ignore trailing slashes.
Type |
Name |
Description |
|
First URL to compare. |
|
|
Second URL to compare. |
public getTemplateType():string
Get type of the currently displayed page.
public setTemplateType($type)
Set the template type from a custom controller. If not defined the template type will fallback to {@see RouteConfig::CATEGORY} on custom routes.
Type |
Name |
Description |
|
The type of the template. |
public is($routeKey):bool
Check if current page is of a given type.
Type |
Name |
Description |
|
Type to check current page against. |
public isLegalPage()
Check if current page is in the list of legal pages.
public fromMemoryCache()
public resetMemoryCache($key = null)
Type |
Name |
Description |
|