Magento ecommerce installations

Magento E-commerce - fun and games

In the past I’ve used Magento as an e-commerce solution.  To be honest I hate developing shopping sites as unless you’ve got the install / setup / design honed to a fine art then problems always arise.  Actually scrub that - problems always arise.  It’s just the many ways that clients can setup a site - especially payment options.

From my early Magento days I remember the setup of both my test site (on Windows XP / XAMPP installation) and the live installation (using UK hosts Heart Internet) being the cause of heightened swearing.

This time I’m trying to hone that procedure so I can eventually produce speedy site installation.

This post will act as my guide and reminder for my sieve like brain.  If it helps anyone else too then all the better.

Why Magento?

Have you seen the other free / opensource shops?  They look rubbish.  Even the best designers seem to struggle or just ignore them.  Magento is different in that the interface for the user looks good.  That’s it’s main winning factor.

When it’s up and running it displays like many top end e-commerce solutions.

Getting it running though is the key.  If you check through the Magento forums you’ll find a plethora of ranting developers.

My notes are displayed below…

My Local Install

I’ll list here what I’ve done, and the problems I encountered.

  • I downloaded Magento full install Version 1.3.2.1
  • I also load the Sample Data file.  Then I created a MySQL database and loaded in the sample stuff.
  • Ensured that PHP is version 5  (I was running version 4).
  • I created a new hostname for 127.0.0.1 call magento in system32/drivers/etc/hosts file.
  • Create the Virtual Host entry in Apache so I can now visit //magento.  Check that works with a wee php file.
  • Now that it’s working I copy the magento installation in that folder, then copy the media folder from the sample data on top.
  • Start up //magento in my browser (Firefox 3)
  • Accept the Terms and Conditions then get to the Locale screen.
  • When I chose UK English / GMT / British Pounds I notice that the first field reverted back to US English and the Timezone had reset too.  I buggered about a bit to have US and British Pounds then onto the next screen.
  • Here I entered the datbase info - keeping “localadmin” as the server, then choosing “Skip URL validation” and the “Database” to keep the admin stuff in.

Problem 1 : Can’t get passed 2nd Magento configuration screen

Damn!!! No matter what options I choose I never get passed this page.  A quick lookup on the Magento forums sees hundreds of others having the same issue.

After a heap of time searching for solutions and trying them out I found one that says…

This is because the latest version verifies whether your MySQL supports
the InnoDB version. If you are using xampp, edit the xampp\mysql\bin\my.conf
file and;

1. Comment the below line (see the # in the beginning):

#skip-innodb

2. uncomment (remove #) the folowing lines:

innodb_data_home_dir = “C:/xampp/mysql/data/”

innodb_data_file_path = ibdata1:10M:autoextend

innodb_log_group_home_dir = “C:/xampp/mysql/data/”

innodb_log_arch_dir = “C:/xampp/mysql/data/”

## You can set .._buffer_pool_size up to 50 - 80 %

## of RAM but beware of setting memory usage too high

innodb_buffer_pool_size = 50M

innodb_additional_mem_pool_size = 10M

## Set .._log_file_size to 25 % of buffer pool size

innodb_log_file_size = 5M

innodb_log_buffer_size = 8M

innodb_flush_log_at_trx_commit = 1

innodb_lock_wait_timeout = 50

you should be able to proceed now..

sajeev

Well Sajeev, whoever you may be. You are my latest hero.  That did the trick and I was able to run through the other pages and get to the Dashboard and the main page.

Problem 2 : Magento can’t log into to Admin Screen

I’d left the system for a few hours then went back to.  But when I try to log into the admin page I keep getting put back to the login page.  There is now “wrong password” error though, and when I try a duff password I do get an error - so what’s wrong now???

After more digging (thanks to Nick Bartlett’s Blog) it seems that Firefox and IE have problems storing cookies with Magento.  Thanks to a tip in the blog post I tried it in Opera and “hey presto”.  But how duff is that? This will have to do for my local machine at the moment.  Hopefully this problem won’t happen on a web server.

Now I want the Modern Magento Theme up and running.  It is this theme that I’m going to copy and redesign for the shop.

  • In the Admin Dashboard I choose System / Magento Connect Manager and login again to this.
  • I then search for the module required, get the extension key and paste it into the field then press install.  If all goes to plan that’s all I need to do.  I wait for the console screen to reveal “Completed”
  • the Modern Theme seems to download a heap of other extensions and upgrades too

Live Magento Install on Heart Internet

Now a smashing fellow called JD (Jeremy) has already posted in the Forums how to install Magento for Heart Internet users.  I’m going to follow the instructions and update below as I install.

  • download the latest version of magento from http://www.magentocommerce.com/download .  I’m using magento-1.3.2.1.zip.
  • check the system requirements - Heart Internet seem to have all the relevant versions and php extensions installed so we carry on - I’m not sure if this is the case with this latest version but we’ll sure soon find out.
  • Unzip the installation file and transfer the files to your site.

Easy to do but this’ll take ages!  I use Filezilla to transfer all the contents of the magento folder into my public_html directory on my site.

  • While uploading the files I created a MySQL database in the normal way using the Heart interface.
  • I then added the sample media using the SQL function - remember to select the  database you are using before running the SQL statement (I didn’t the first time and got an error message)
  • If all goes well you should have around 229 tables loaded into the database
  • note your database name and password

Right.. this upload will take a few hours.  Time for tea.  Curry tonight :o)

Ok.  Now all the files have transferred including the sample data.  Next we need to ensure the correct permissions are set against specific folders.

  • the file public_html/magento/var/.htaccess,
  • the folders /public_html/magento/app/etc/public_html/magento/var,  and all the directories under /public_html/magento/media all set to 777
  • ensure that file /public_html/magento/index.php and the magento directory itself are both set to 755
  • Edit the file /public_html/magento/.htaccess and add the following:
    #############################
    ## For heart internet
    SetEnv DEFAULT_PHP_VERSION 5
    php_flag short_open_tag on
  • Create a new text file within /public_html/magento/ called php5.ini
    put the following in this file:

    php_flag short_open_tag on
  • Now.. check everyhting!!
  • Visit the site and the installation process should begin…

More info to come later…

Bookmark This
[del.icio.us] [Digg] [Facebook] [Google] [LinkedIn] [MySpace] [Reddit] [Technorati] [Twitter] [Windows Live] [Email]

Tags:

Leave a Comment

News Website

Arras Wordpress Theme

Arras Wordpress Theme

I got a hold of a great Wordpress Theme called Arras.  It’s a magazine / news styled theme and so I’ve put together a news site with some made up stories.

The theme is well put together and I heartily recommend it.

I’m also working on a heap of SEO tasks to try and drive visitors to the site including using Twitter and Facebook links.  I’ll report of the following weeks where the traffic is coming from (if any!).

If you manage to get a look, tell me what you think of it.  You can visit the site at http://www.solarpolar.co.uk/madeupnews.

Bookmark This
[del.icio.us] [Digg] [Facebook] [Google] [LinkedIn] [MySpace] [Reddit] [Technorati] [Twitter] [Windows Live] [Email]

Leave a Comment

Busy Busy Busy

Busy is good and it’s been a very busy week in the wonderful world of the internet.

While catering for some lovely folks this week I’ve also been attempting to upgrade the “Social Network” plugin for Wordpress.

You can currently see it on the right hand side of the page in the right sidebar.  It shows links to the Social Network sites I frequent, but I’d like this to display in a much better format.

Hopefully more like the style that Tim Van Damme has created / re-invented (check out his Love and Hate pages at the bottom!).

If and when I get it done I’ll credit him and the other developers for it.

Google searches

Yay!  This week our “Solar Polar” search returns us back at the top of the Google UK searches and on page 1 of Google.com.

The updated site has been read and listed by the crawlers so now there’s no stopping our world domination.

More good Wordpress SEO practices will be actioned now and I’ll list what I’ve been doing to push us up the lists.  Today Google, tomorrow Bing - ooops, just checked Bing and we’re on Page 1 there too :o)

Bookmark This
[del.icio.us] [Digg] [Facebook] [Google] [LinkedIn] [MySpace] [Reddit] [Technorati] [Twitter] [Windows Live] [Email]

Leave a Comment

Can only access some Internet sites

A strange occurrence happened yesterday. I’m still not sure what triggered it but will post about it if and when I find out.

As a regular visitor to some sites (myspace.com as an example) I found that my main development PC couldn’t access some sites using any browser. I tried Firefox, IE and Safari. Still no sites. My other 2 pcs could access the sites so I firstly assumed that it probably wasn’t a router problem.

I tried all the usual things - reboot pc, reboot router, turn off firewall and antivirus software, turn off all the other un-required background programs but still no joy.

Then I was left to search the Internet for a solution.

After a bit of web trawling I found my solution thanks to the pages of “Ask Leo”. His helpful post here highlighted the problem. I downloaded the DrTCP utility and could then easily change the registry settings.

Essentially, a network configuration setting had changed. The “Max MTU” settings against my network card were all set to “blank”. I reset these to 1300 (the setting on my other machines) and after a reboot I can again visit everywhere on the internet.

Thanks and kudos to Leo’s site.

Bookmark This
[del.icio.us] [Digg] [Facebook] [Google] [LinkedIn] [MySpace] [Reddit] [Technorati] [Twitter] [Windows Live] [Email]

Tags: , ,

Leave a Comment

Multiple Virtual Hosts on Windows XP

Running multiple local websites on XP

When testing websites I need to access more than just my standard Windows server at http://localhost. It’s possible to run more than one server using the Apache Virtual Hosts feature.

Note: I have XAMPP setup on my Windows XP system, which is running Apache 2.2.

I’ll display below how I set up my additional “paytest” virtual server.

First of all you’ll need to edit the Windows Hosts file. You can find this file in C:\WINDOWS\system32\drivers\etc\hosts. Edit it using Notepad.

Because I’m adding a “paytest” virtual host my updated file looks like;

# Copyright (c) 1993-1999 Microsoft Corp.
#
# This is a sample HOSTS file used by Microsoft TCP/IP for Windows.
#
# This file contains the mappings of IP addresses to host names. Each
# entry should be kept on an individual line. The IP address should
# be placed in the first column followed by the corresponding host name.
# The IP address and the host name should be separated by at least one
# space.
#
# Additionally, comments (such as these) may be inserted on individual
# lines or following the machine name denoted by a '#' symbol.
#
# For example:
#
#      102.54.94.97     rhino.acme.com          # source server
#       38.25.63.10     x.acme.com              # x client host

127.0.0.1       localhost
127.0.0.1       paytest

Once you’ve saved the hosts file make sure your Apache server is not running.

Now we’ll need to edit the the Apache Virtual Hosts configuration file. My installation of Apache is in C:\xampp\apache so the file that I have to update is C:\xampp\apache\conf\extra\httpd-vhosts.conf.

My file now looks like;

#
# Virtual Hosts
#
# If you want to maintain multiple domains/hostnames on your
# machine you can setup VirtualHost containers for them. Most configurations
# use only name-based virtual hosts so the server doesn’t need to worry about
# IP addresses. This is indicated by the asterisks in the directives below.
#
# Please see the documentation at
# <URL:http://httpd.apache.org/docs/2.2/vhosts/>
# for further details before you try to setup virtual hosts.
#
# You may use the command line option ‘-S’ to verify your virtual host
# configuration.

#
# Use name-based virtual hosting.
#
NameVirtualHost *

# this is the default mapping to http://localhost

<VirtualHost *>

DocumentRoot “C:/web/localhost”
ServerName localhost

</VirtualHost>

# the new virtual host mapping to http://paytest/

<VirtualHost *>
DocumentRoot “C:/web/paytest”
ServerName paytest
<Directory “C:/web/paytest”>
Options Indexes FollowSymLinks Includes
AllowOverride All
Order deny,allow
Deny from all
Allow from 127.0.0.1
</Directory>
</VirtualHost>

Note that the NameVirtualHost entry at the top has been uncommented. That was my first mistake and Apache didn’t restart. Also be careful of typos as Apache won’t restart if you’ve typed something in incorrectly.

Once you’re happy with your addition then restart Apache.

You should now be able to vist http://localhost and http://paytest in your browser and the pages should now visit the appropriate folders.

If you have more customisations to make to your virtual sites (e.g. log files etc…) you can include the changes within each VirtualHost entry, like the Directory changes above.

Bookmark This
[del.icio.us] [Digg] [Facebook] [Google] [LinkedIn] [MySpace] [Reddit] [Technorati] [Twitter] [Windows Live] [Email]

Tags: , ,

Leave a Comment

Bottom HR