On my Porto theme with Magento, Currency Switcher is not working on category_list page and product_view page. On both of these pages, switching the currency always returns Base Currency. Using the URL like this

http://example.com/catalog/category/view/id/82 (working well)

works fine i.e., the currency changed. Also getting the visitor's information using following method returns the array with information.


But with the URL with URL key doesn't work. and getVisitorData() returns NULL value on the links with URL-key like following.

http://example.com/category.html (doesn't work)

Please help me to figure this out. Thanks in advance :)

2 Answers 2


hello @Muhammad Salid,

Why you don't use a extension for it ?

For example: http://goo.gl/LUpfa3

  • thanks @michel but the extension is paid. Also I just want to run the default functionality first. May 13, 2016 at 5:23

AFAIK the visitor data is set in the session in


public function saveByRequest($observer)
    if ($this->_skipRequestLogging || $this->isModuleIgnored($observer)) {
        return $this;

    try {
    } catch (Exception $e) {
    return $this;

You've got three things to debug.

  1. Is your module ignored? Pop logging in the isModuleIgnored function.
  2. Is the _skipRequestLogging set to true? It seems to be based on config and depending on the user agent. See Mage_Log_Model_Visitor::_construct.
  3. Is there some sort of exception happening, check your exception log.

It's going to be one of these failing. My bet would be on points 1 or 2 but that's pure conjecture.

  • Thanks @Luke 1) isModuleIgnored returns False and 2) _skipRequestLogging set to False. Also No exception in exception.log May 16, 2016 at 7:57

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.