Skip to content

Instantly share code, notes, and snippets.

@michaelhoang
Created April 25, 2015 04:19
Show Gist options
  • Save michaelhoang/1be959b1dbe49f9d9aec to your computer and use it in GitHub Desktop.
Save michaelhoang/1be959b1dbe49f9d9aec to your computer and use it in GitHub Desktop.
Magento Url Utilities
// Get new url base current url
$url = Mage::getUrl('/*/*', array(
'_use_rewrite' => true,
'_query' => array(
'param1' => 'param1',
'param2' => 'param2',
'param3' => 'param3',
),
));
// Get current url
$currentUrl = Mage::helper('core/url')->getCurrentUrl();
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment