December 27, 2010

“Remember Me” checkbox module in Magento

Hello everyone! I’ve created a small and simple module that creates “Remember Me” functionality to any Magento website. Its currently in testing phase, so I’d say it’s an alpha release.
Never mind the alpha release (v 0.1.0), if someone is willing to try it and trace possible bugs, I’ll do my best to fix them. :D
Module doesn’t have any admin functionality. Though it can be disabled through admin at any time. There’s a small change on customer/form/login.phtml file (added checkbox with input name set), and besides that, only thing is that this module will save hashed and salted Magento customer’s password hash in a cookie, so it is safe as it can be (if I’m wrong, I’m opened for suggestions).
There’s nothing else to say besides it’s placed on login form for Magento customers. It looks like this:

As far as setting it up goes, you only need to extract attached file over your “app” folder (it won’t overwrite anything, I’ve set it up like this because of the folder structure).
And a small note, It’s been tested on community version 1.4.
And here’s the download link.
And one last thing, I’d like to hear your opinions on this one, as this is fist module that I’ve created and have given it to public.
Cheers!

Magento 1.4.0.1 Google Analytics fix

Magento 1.4.0.1 Google Analytics fix
If you updated to latest Magento 1.4.0.0 or 1.4.0.1 version you may notice that Google Analytics implementation is broken. Here are few easy instructions how to fix this.


Navigate to and open app/code/core/Mage/GoogleAnalytics/Block/Ga.php and add this on line 179

var _gaq = _gaq || [];


Since this bug is already reported and fix can be seen on latest official svn, I don’t see any harm in modifying core files in this particular situation.


http://www.magentocommerce.com/bug-tracking/issue?issue=8658
http://svn.magentocommerce.com/source/branches/1.4-trunk/app/code/core/Mage/GoogleAnalytics/Block/Ga.php
As Magento Team said, changes will be included in next stable release.