Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <p>Your "category" object might be actually <em>null</em> in Chrome, i.e., did you call <code>Mage::register</code> on <code>current_category</code>?</p> <p>Check the URL and call that opens that page, or verify it is not a session issue (e.g. you have data in the Firefox session, but not the Chrome one).</p> <p>Depending on how you arrived at that page, you might be in an area where <code>current_category</code> is not (yet?) set by <code>CategoryController::_initCategory()</code>, because for example the category is not present in the URL. See <a href="https://stackoverflow.com/questions/6264514/any-reason-why-mageregistrycurrent-category-would-return-null">this answer</a> for some more details. Suppose now that the category is saved in the session and you made several page hits with Firefox. Now the Firefox session <strong>does have</strong> a cached category available, and when you hit the troublesome cache in Firefox, you see the cache. Then hit that same page with Chrome which has no session or cache available (yet), and that gives you an error.</p> <p>You may want to wrap the call with some fallback code, to sidestep the problem and not use the category code unless there is indeed a category available:</p> <pre><code>// Here you might get NULL $current_category = Mage::registry('current_category'); // If category is **not** NULL, *and* is Showroom, then... if (($current_category) &amp;&amp; ($current_category-&gt;getName() == 'Showroom')): </code></pre> <p>Depending on where you are in the code, you can check more ways of getting the category; see <a href="https://stackoverflow.com/questions/10282847/magento-registry-and-current-category">this answer</a> for details.</p>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. VO
      singulars
      1. This table or related slice is empty.
    2. VO
      singulars
      1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload