Getting Started with Magento Ecommerce!

Getting Started with Magento Ecommerce!

Magento is the next generation of eCommerce! It is incredibly well architectured, fully flexible, scalable, and fun to work with. If you’ve ever thought about creating an online shop, Magento is your choice! Today we are going to install it locally with XAMPP Lite and review the essentials.

Step 1 – What’s Magento?

“Magento is a feature-rich, professional open-source eCommerce solution that offers merchants complete flexibility and control over the look, content, and functionality of their online store. Magento’s intuitive administration interface contains powerful marketing, search engine optimization and catalog-management tools to give merchants the power to create sites that are tailored to their unique business needs. Designed to be completely scalable and backed by an extensive support network, Magento offers companies the ultimate eCommerce solution.”

That’s Magento in their own words. Very cool about Magento is the concept behind it. Due to its high OOP style, you can
easily integrate it with your own solutions.

Step 2 – Downloading Magento

First of all we are going to download Magento. Browse to magentoecommerce.com/download and select your preferred format of Magento. You can choose between a smaller “Downloader” version which will get the files during the installation process and a “Full Release” which already contains all files. Take the sample data as well since they are helpful for getting used to Magento

Step 3 – Downloading XAMPP Lite

XAMPP Lite is a Take-Run-Delete-Forget-it package which doesn’t require an installation. XAMPP Lite contains Apache, MySQL 5.1, PHP 5.2, phpMyAdmin 3.1 and much more. It is an extra small edition of its big brother
XAMPP. It brings (almost) everything we need for Magento. You can neither take the zip file or the selfextrackting zip archive: http://www.apachefriends.org/en/xampp-windows.html#646

After you are done downloading, extract XAMPP Lite to your HD like so X:/xampplite (where X is the letter of your partition).

Step 4 – Setup XAMPP Lite

Magento makes high demands on the servers hardware and software. That’s my we need to adjust XAMPP Lite a bit. Some extensions must be loaded in additionally. Within the two files D:\xampplite\apache\bin\php.ini and D:\xampplite\php\php.ini we need to uncomment 4 lines of code

In both files search for

  • ;extension=php_curl.dll
  • ;extension=php_mcrypt.dll
  • ;extension=php_mcrypt_filter.dll
  • ;extension=php_mhash.dll

…and remove the semicolon to uncomment them like so:

  • extension=php_curl.dll
  • extension=php_mcrypt.dll
  • extension=php_mcrypt_filter.dll
  • extension=php_mhash.dll

Step 5 – Replace libmysql.dll

In order to get Magento working we need to replace the libmysql by a newer version. Simply download http://windows.php.net/downloads/snaps/php-5.2-win32-VC6-x86-latest.zip and copy the included libmysql.dll to the folders D:\xampplite\apache\bin\ and D:\xampplite\php\.

Step 6 – Start XAMPP Lite

Click on D:\xampplite\xampp-control.exe to start the control panel. Within that panel you can launch the Apache server and the MySql server.

Step 7 – Creating new DB

Browse to 127.0.0.1/phpmyadmin to open phpMyAdmin. Choose the name of the database (‘magento’ is a good choice ;-) and click ‘create’.

Step 8 – Installing sample data

Magento’s sample data have to be installed before installing Magento itself. Otherwise there will be an error.

Got to the tap ‘import’ and choose magento_sample_data_for_1.2.0.sql which you downloaded in Step 2.

Then click ok to execute the import. This will take a while (at least 20 seconds). So please be patient and do not interrupt that process. The result should look like this:

Step 9 – Installing Magento

First extract magento-1.3.0.tar.bz2 that you downloaded in Step 2 to your htdocs folder: D:\xampplite\htdocs\magento\. Make sure all files are in that folder, including the index.php. Your directory structure should look like this:

Then open localhost/magento in your browser. Magento will now start the installation wizard. First you will need to accept the license.

Choose your Localization and your currency and go on. Under ‘Configuration’ you can leave every thing as it is. In a productive Environment you would need to enter the admission data you got from your hosting company.

In the next step you need to create your admin account. Enter your personal data and your login information. Your can leave the field for ‘Encryption Key’ blank.

After you confirmed your Login Information with ‘next’ you finally finished the installation.

Step 10 – Make yourself familiar with Magento’s frontend

When you click on ‘Go to Frontend’, it will redirect you to localhost/magento/. Now you can discover the store with its sample data, add products to cart or try Magento’s famous one-page-checkout. Just play a bit with your fresh Magento Store.

Step 11 – The Admin Backend

When going to Magento’s administrative user interface, the backend, make sure to use 127.0.0.1 instead of localhost. Some browser do not save cookie information when there isn’t a dot in the domain. Magento needs cookie information to identify you as approved to the backend.

Visit http://127.0.0.1/magento/admin/ to login. Once you entered your Account Information you’ll be redirected to the Dashboard.

Step 12 – Intro to Themes

You can install a theme through a platform called “Magento Connect”. A theme in Magento is responsible for the visual output.

Magento has a very powerful theme concept. For instance, you can use a default theme which comes with Magento and a new one of your own side by side. That new individual theme only contains files which differ from the default theme.

If you simply want to move the mini cart from the left sidebar to the right sidebar you just copy the according file from “default” to your new theme directory and adjust some code. Magento first loads all files from your private theme and then falls back to the next theme lower in hierarchy (in this case “default”) and requires all missing files from that theme.

Doing so, Magento conserves the ability to be upgraded. With every Upgrade pushed out by the Magento Team, files in your default theme are getting overwritten. Your adjusted files are protected this way.

Step 13 – Where to begin with themes?

Magento themes are split into two directories. When working with themes, these two directories will remain your base starting point.
The files are separated into “web accessible” (such as image and Javascripts) and those that can be hidden from it for security reasons.

  • Directory 1: app/design/frontend/default/default/ — This directory contains the layout, translation (locale) and template materials.
  • Directory 2: skin/frontend/default/default/ — This directory contains the images, CSS and block-specific Javascripts.

Step 14 – Interface and theme

An interface is a collection of themes. Let’s have a look at the two directories as they represent the structure of interfaces and themes:

  • Directory 1: app/design/frontend/default/default/
  • Directory 2: skin/frontend/default/default/

In both cases, default indicates the interface name, and default indicates the theme name. So if you were working on a theme called “my_theme” in an interface called “my_interface”, you would be working in the ‘app/design/frontend/my_interface/my_theme/’ directory.

Step 15 – What are Blocks?

In Magento we work with structural blocks and content blocks. Structural blocks represent the basic structure of a page. Usually we have structural blocks like header, left sidebar, middle content, right sidebar and footer. We can assign content blocks like category list, navigation, search bar, callout etc. to a certain structural block.

Step 16 – Intro to Layout

Content blocks are assigned to structural blocks with the help of layout. Layout is build with XML files and can be found under app/design/frontend/default/default/layout. This way you can reuse earlier created templates, such as the mini cart module on the sidebar, on different pages by simply calling them within a layout xml file.

Step 17 – Roundup

You learned how to setup Magento and the basics of Magento’s design terminologies. This will help you diving into that wonderful Open Source platform. To dive deeper into Magento, I recommend the following resources – which cover the fundamentals.

Main Resources

  • http://www.magentocommerce.com
  • http://www.magentocommerce.com/design_guide
  • http://inchoo.net/wp-content/uploads/2008/06/designers_guide_to_magento.pdf
  • http://www.magentocommerce.com/media/screencasts
  • http://www.magentocommerce.com/media/tour

Books

Note: Want to add some source code? Type <pre><code> before it and </code></pre> after it. Find out more
  • Joe

    Oh !!! this is very helpul to all ,you can get good idea over this notes

  • http://www.jashsayani.com Jash Sayani

    My internet is too slow, it took several hours to upload the files to my webserver and it disconnected somewhere in the middle.

    Is there a way to trans-load it to my webserver directly from Magento ?

    • Cleefy

      If you have ssh access, you can use a wget command to cut out the middle man and install magento easily.

      Feel free to contact me at mick [dot] cleef [at] gmail [dot] com for more information

  • http://www.zuigeling.com Alfred

    Prestashop is another alternative to MAGENTO

    I found Prestashop to be easier to install and modify although not as full featured as MAGENTO, Prestashop is great for my small shop :)

  • http://www.lrgstudios.com john Doe

    I think a series on Magento would be a big hit.

  • David

    love magento.. would love to see a detail tutorial about skinning magento..

  • Mik

    this magento initiation is most than welcome! thank you. For the people who already roam on magentocommerce, there is nothing very new, but again, this is an excellent idea, please do keep up with the great job and offer tutorials on theming and module development !
    :)

    We are currently migrating from Miva5 to Magento, with a multistore configuration (12 stores), for a combined monthly volume over 200K$
    Magento turned out to have the most potential for us compared to the ageing competition, and thus far we’re not deceived.

    Be prepared to spend countless hours understanding the structure in order to make things right, but with the right resources and people, it just plain works.

  • http://www.garethpjones.co.uk Gareth Jones

    Just starting using Magento, looks really straightforward. Finally a creative solution to commerce.

  • http://www.algozone.com osCommerce Templates

    Thank you for posting a very clear steps on how to install Magento. I have been using Magento for several months now and I know that I still need to learn a lot of things about the software. This will definitely help me.

  • http://blog.insicdesigns.com insic

    I received quite a lot of bad feedback about this magento thing in my blog. I found it usable but others has its reason why they don’t like it :)

    Any way well written tutorial.

    • Jhon

      hy insic nice face..

  • http://trinelight.com evodanh

    Thanks for your tutorial. I’m using Magento for the next project.

  • Julie Berlin

    I’ve used OScommerce, ZenCart, (both are pretty clunky – themes are good but I was always worried about the security and lack of admin features) and am in the process of theme-ing a Magneto site. So far, it seems more robust than the first 2 but it’s definitely overkill for the small site I’m building… are there any simpler OS shopping carts that are still secure?
    I’d love a comparison of security and features of OS shopping carts. I did find some online but the info seems dated. I have learned so many CMS’ and shopping cart systems only to find that they are not good enough for what I need to accomplish – I’m happy to devote time to learn an app that will continue to be updated and has features that we know we need to use now – Magneto is so far the best I’ve found for e-commerce… but please do tell if there are others!
    Also looking forward to the subsequent tutorials on Magneto.

    • v

      You could check on PrestaCart. It’s a lot less clunky than Magento, but my experience is limited…

  • Augusto Esteves

    On the installation it doesn’t allow me to change the Locale to Portuguese, it keeps changing it to English. Why is that? Do I need a language pack?

    • http://twitter.com/vegevore Mexx
      Author

      Yes, at the beginning Magento is English only. After your done installing go to http://www.magentocommerce.com/magento-connect and get the key of your language pack. Then browse in the admin to system->magento connect->connect manager. Enter the key there and click install. And your done ;-)

  • Cleefy

    This seems to be a direct copy of the designers guide to magento located on the http://www.magentocommerce.com site.

  • http://www.carbonfibergear.com Dave

    I have gone back and forth wanting to use Magento, and always found issues. Now with 1.3.0 it seems like the performance is a lot better, and I’ve recently launched my store utilizing the system. You can check it out here:

    http://www.carbonfibergear.com/direct

    It does take a large learning curve to figure out how things work, but once you do, it’s not TOO bad. Even though I was modifying their default theme, it still took me a good 40 or so hours to customize and set everything up. So far, well worth it though. I do have some gripes about small things, but the benefits far outweigh them.

    • Pablo

      Dave,
      The performance of your store is great. Can you share some of the details of how you are hosting Magento? If I can get it running this fast I can live with it.

  • http://www.jorggray.com jg

    We too considered and compared Magento, osCommerce and ZenCart. After running several test of Magento and selecting a good hosting provider we were up and running live in 2 weeks : http://www.jorggray.com.

    There are a few issue’s we’re sorting out, but for the most part, it runs very well.

    Thanks for the article. BTW. I used virtualbox -> installed ubuntu 8.10 desktop -> installed XAMPP (regular) -> installed magento…

    Works like a treat!! :D

    • Lazar

      Hi,
      Nice site, what did you use to get magnifier glass on images.
      Thank you,

    • EGY

      Where did you learn to use Magento like that? Your site design is amazing. Could you please let me know how you do it or where you find the learning materials to do it? Thanks.

    • Pablo

      Nice store. Like Dave’s your store really performs well. Can you share what kind of host platform you are running on to get it to run that fast? Thanks.

  • http://www.sohointeractive.com SohoInteractive

    Our clients love Magento. It is not easy to customize, but it’s well worth it. Stable, secure and powerful.
    Thank you for the Tutorial Max.

    K.

  • Jay

    I tried and tried and tried to install magento on godaddy shared hosting and couldnt get it to work. Just a head’s up for anyone who has gsh and is going to try it out.

    Other than that it looks like great e-commerce software.

  • http://fearlessflyer.com Michael Soriano

    Love it! This definitely helps.
    Watch out World for my Magento Themes!

  • Denis

    Hi… thanks for the post…
    but i have some troubles..

    C:\xampplite\apache\bin\php.ini dont exist!
    what to do?

  • Jay

    @denis

    just change the .\xampplite\php\php.ini and dont worry about the other one.

    depending on whether you are using xampp or xampp lite it can be in either place. xampp lite is only in the php file.

  • http://www.klausy.net klaus

    Whats up with steps 4 5 6 , that’s not on men.. should be simpler

  • http://www.designsolutionsmd.com Ruslan Lisitsa

    Hi Maxx

    First, Great Tutorial.

    I like magento much more than the others ecommerce open source solutions.
    I do have a couple of requests, I am sure I will not be the only one to benefit from.

    I have had nothing but trouble installing Magento on my remote server.
    Could you make a tutorial focusing just on that?

    Also could you make some tutorials on customizing the frontend appearance of magento.

    For example a great tutorial would be on how to make the default horizontal nav vertical.

    Thanks so much for great help.

  • shrikant

    Hi Max

    Its a a great article however after step 9
    i get following error message can you please help me
    No releases for package “magento-core/Interface_Install_Default” exist
    Failed to download pear/Archive_Tar within preferred state “stable”, latest release is version , stability “”, use “channel://pear.php.net/Archive_Tar” to install
    magento-core/Mage_All_Latest requires package “magento-core/Interface_Install_Default” (version >= 1.3.1, version = 1.6.2)
    magento-core/Lib_Google_Checkout requires package “magento-core/Mage_Pear_Helpers” (version >= 1.0.18800)
    magento-core/Mage_Core_Modules requires package “magento-core/Lib_Google_Checkout” (version >= 1.2.0, version = 1.3.1.1, version = 1.3.1, version = 1.3.1, version = 1.0.18800)
    magento-core/Lib_Js_Prototype requires package “magento-core/Mage_Pear_Helpers” (version >= 1.0.18800)
    magento-core/Mage_Downloader requires package “magento-core/Lib_Js_Prototype” (version >= 1.3.1, version = 1.3.1, version = 1.0.18800)
    magento-core/Lib_ZF requires package “magento-core/Mage_Pear_Helpers” (version >= 1.0.18800)
    magento-core/Lib_Varien requires package “magento-core/Lib_ZF” (version >= 1.7.2.2, version = 1.0.18800)
    Install Errors
    No valid packages found
    PEAR ERROR: install failed

  • http://e-atat.co.cc geo

    Magento is a great Ecommerce platform, i would be using it too but my host hasn’t all the requirements for magento so i’m using Interspire which is a amazing piece of scripting .

  • http://www.jigowatt.co.uk James Koster

    Some examples of great Magento web sites here: http://www.magentoshowcase.co.uk/

  • Lesya

    If you also want to be the one of Magento users you may try cart2cart web service. This service will automate data migration fm your shopping cart to magento. For details you can check http://www.shopping-cart-migration.com

  • Balasundaram.G

    There is no PHP.INI file in xampplite/apache/bin…

    What to do?? phpmyadmin doesn’t running…

    need help

  • Balasundaram.G

    i can’t install magento with xampp, while using xampplite i’ve experienced major problems, phpadmin doesn’t running, no php.ini file in apache/bin folder..

    what to do?

  • http://www.magentothemes.com Magento Themes

    I’ve never seen such a detailed guide to magento! Going all the way through the process of even setting up your server with all the PHP addons and such. What an awesome guide ! Thanks for the post.

  • Wolf

    Hi Mexx, hi all,

    Why should I use Xampplite ?

    I’ve installed Xampp 1.7.2 (PHP 5.3, MySQL 5.1) local in WindowsXP and want to install Magento inside it ? Is it possible ? Has anybody experience ?

    Thanks for tips. :-)

    • JohnRubins

      hi,
      I have tried installing magento on xampp 1.7.2.
      I got an error on depreciated functions such as toString and split.
      But you can fix them by replacing the toString with invoke
      and split by explode.

  • rj

    Great site. Found the tutorial with screenshots very useful

  • martin

    Great topic
    For quick fix of installation issue of XAMPP please go to http://cookphp.blogspot.com/2009/10/magento-xampp-17-installation-error.html

  • http://www.unsworthsugden.co.uk John Public

    I am pleased you approve of Magento. I have chosen it for one of my ecommerce websites. Thanks for the tips above

  • phpini

    nice tutorial

  • http://www.zaptechsolutions.com/open-source-web-development/magento-development.php Magento Ecommerce

    Nice article on magento installation. Thank you for providing step by step tutorial with picture. It’s perfect..

  • The Integrator

    The SOAP/XMLRPC API is a total nightmare to work with. You cannot create configurable products, attributes, attribute sets etc through the SOAP API. Also if you are planning using it for a commercial heavy traffic site, with integration to a physical store company with more than 100 products it will take your site down if you publish those products through the API. The documentation is terrible.

  • http://www.media-street.co.uk/services/web-design Media Street Web Design

    Thanks for the article. Much appreciated.

  • http://www.cooldesktopbackgrounds.net cool desktop backgrounds

    i really must give this package a try – keep hearing good things about it.

  • http://mushroomdigital.co.uk web design staffordshire

    Very appreciated for the tutorial. Excellent

  • http://www.ijewebservices.com Magento Commerce

    This is certainly a good way to work with Magento Commerce- if anyone wants a quicker -automated- way to install it on a server you should check out this script: http://snipt.net/lecomm/install-magento – this is what we use at work

  • http://www.merixstudio.com Kamil Kaniuk (Merix Studio)

    Good introduction,

    We experienced increase of Magento queries and generally demand for Magento development services seem to grow fast though…

  • http://ebanat.com Tis

    Thank you very much for this tutorial! It is great

  • http://pixert.com Kate Mag

    Thank you so much for this tutorial. It’s easy to read

  • Wilson

    I’m doing Step 5 – Replace libmysql.dll now but the link you gave is dead – http://windows.php.net/downloads/snaps/php-5.2-win32-VC6-x86-latest.zip. Kindly provide another link. Thanks in advance.

  • http://www.xpertdeveloper.com Addy

    Nice tutorial.
    I have just started learning magento and this is really helpful to start with.

    Thanks
    Addy

  • http://seanjacob.com seanjacob

    @Wilson and anyone else having trouble with the broken link in step 5.

    http://uk.php.net/get/php-5.2.12-Win32.zip/from/a/mirror

  • http://www.brillcreative.co.uk design bristol

    Useful Magento Template web design tutorial! Why can’t everyone explain Magento in a step by step fashion?

    Good stuff.

  • http://ultralightcomposites.com/ ultralightcomposites

    i will try this magento and see what it looks like with my site. I recently have installed Joomla, but i will try out this magento. I think this is good too, love to start working on it.

  • http://www.tronus.nl Design Bureaustoel

    Thanks for the info. I’m going to use it to build the 2.0 version of my webshop;

    http://www.tronus.nl/

    Are there any other starter-guides you guys reccomend reading?

  • http://giaothuongtructuyen.com jam

    thanks ! i have diff in install magento ! also i set-up it on live host ! haizzzzzzz