Ok… so you’re all excited about finally getting your new Magento store installed! BUT, what happens? You log into the Admin area of your site and click on the message popup to “view message inbox” and… It’s a blank list! Even though it says there’s 65 messages there… they’re not listed.

Or worse, it looks more like the example below:

Then you start noticing that other pages that use the list control are doing the same thing… what’s going on!? Don’t worry… just another one of those pesky Magento bugs that crept in from 1.6.0 and STILL hasn’t been fixed in 1.6.2.
The problem has to do with a the method in the core code that calls the Row items for the list. It freaks out and then returns an empty object… so, you get back a blank list. In some cases it may even mess up the formatting of the entire page.
The Solution
Thanks to Sanjeev for this solution! To fix this one you’re going to have add a directory under your ‘app/code/local’ folder, move a php file from your core code collection, and then edit it’s content.
If you are not comfortable with doing this, please don’t attempt it, as this could have severe implications to your Magento store if it’s not done right.
Step 1
Create a new directory structure under ‘app/code/local’ called ‘Mage/Adminhtml/Block/Widget’.
So your full path from your Magento root directory will be ‘app/code/local/Mage/Adminhtml/Block/Widget’.
Step 2
Copy a file called “Grid.php” from ‘app/code/core/Mage/Adminhtml/Block/Widget’ to your new directory that you created: ‘app/code/local/Mage/Adminhtml/Block/Widget’.
Step 3
Browse to the location of the copied file now in ‘app/code/local/Mage/Adminhtml/Block/Widget’.
Use Vim or a similar tool to edit the contents of the “Grid.php”. Alternatively, you can download the file to your local machine, make the changes and then upload again to the new folder you created.
Make the following update:
Around line 1642 you will locate a function called: getRowUrl($item)
It should look something like:
public function getRowUrl($item) { $res = parent::getRowUrl($item); return ($res ? $res : '#'); }
Delete the php code contained in the method. ie. between the curly braces {} and replace it with the following line of code:
return $this->getUrl("*/*/edit", array('id' => $item->getId()));
So now your method definition should look as follows:
public function getRowUrl($item) { return $this->getUrl("*/*/edit", array('id' => $item->getId())); }
Save the file.
Step 4
In the final step, you need to clear the Magento cache and recompile using the Compiler to include the updated code.
I’d recommend first disabling the Compiler, then clear the cache and finally recompiling. This is just a good practice to prevent any stray code from creating a runtime error, which has happened to me in the past.
Lastly, if you log out of the admin area and back in again you should now see that all the Admin area lists are functioning as expected.
A Final Word
If you have made all the above updates and it is still not working, please double check the permissions on the new directories you created, as well as the copied file.
In Magento all files should generally have ‘644’ permissions and the directories ‘755’. Also, it’s good practice to ensure that the user running your web service is the owner or group owner of the directories and file.
If these were not correct, once you’ve updated your permissions you’ll have to complete Step 4 again for the changes to take effect.
Beon de Nood
Latest posts by Beon de Nood (see all)
- FileMaker on iPad in the Enterprise? - April 10, 2013
- The Day We Blew Away WordPress - April 6, 2013
- Magento Paypal IPN Wrong Order ID - February 15, 2013


