Posts Tagged ‘Magento’

Copy or move Magento to another instance

Posted on Saturday 30th January 2010 under IT by Adrian

A quick how-to if you want to copy or move Magento to another database instance, e.g. to create a test site, or move test to live.

(1) Backup Magento using the built in backup tool. Download and uncompress the resulting SQL script. If changing the server or domain, search and replace “old.mysite.com” with “new.yoursite.com” Execute it to populate the new database instance.

(2) Copy all Magento files with the exception of the contents of the var/ directory.

(3) Edit app/etc/local.xml on the target instance and change the database, user and password, but not the encryption key. Also edit downloader/pearlib/pear.ini to correct the absolute paths it contains; no reason why these shouldn’t be relative to the Magento root directory, e.g. “./downloader/pearlib”.

(4) Execute the following SQL to prevent those nasty “Integrity constraint violation: 1062 Duplicate entry” errors from the log files when adding to the basket:

TRUNCATE `log_customer` ;
TRUNCATE `log_quote` ;
TRUNCATE `log_summary` ;
TRUNCATE `log_url` ;
TRUNCATE `log_url_info` ;
TRUNCATE `log_visitor` ;
TRUNCATE `log_visitor_info` ;
TRUNCATE `log_visitor_online` ;

Now tidy up permissions:

chmod o+w var var/.htaccess app/etc
chmod -R o+w media

That should be it.

reCAPTCHA for Magento

Posted on Friday 31st July 2009 under IT by Adrian

Well done Fontis for integrating reCAPTCHA into Magento to prevent SPAM through the contact form and “social” pages. About time!
Well though-out and integrated beautifully into admin.
Keys are required from reCAPTCHA andthe extension can be installed through Magento Connect using the extention key on the Magento Extention page.

Magento

Posted on Thursday 7th August 2008 under IT by admin

Since I last looked (around 9 months ago, I think) the Magento web store project seems to have shaped up nicely. It is certainly prettier than OSCommerce, but more importantly they have kept the code and the presentation separate using – of course – CSS.

It is written in PHP, and has a growing collection of add-ins, so I’ll be seriously evaluating it as an alternative to OSC for the Oriental Food Shop.