Magento index – The basics, benefits and tips to avoid errors

What does Magento indexing mean?

Definition 1:

 

Indexing is the process when Magento transforms product, category etc. data in order to achieve the fastest request speed.

 

Definition 2:

Data storage in MySQL in order to have the most appropriate indexes for SQL requests.

 

What would happen if there were not indexing in Magento?

All the following examples below show that Magento indexes have significant benefits in terms of ecommerce store performance. Even in the case of only one product it is worth running the index, though you should keep in mind that with one product, there is only a little increase in speed. So if you did not use Magento indexing, the you would face some serious drawbacks:

  1. Prices would be calculated in terms of download speed, on the basis of shopping cart price rules and customer groups.
  2. Calculation of inventory for configurable and bundle products would take place only after loading the product collection.
  3. „Layered navigation” would be generated in real time on the basis of hundreds of product attributes.
  4. The products within a category’s sub-categories, would be queried in a recursive way.

 

Jargon in Magento indexing

Before describing the process of performing Magento index, it is important to clarify a few basic terms.

  • Indexed data – The data set which defines the user interface display
  • Indexer – Procedure suitable for creating data arrays
  • Index event – The event or moment when the source data is modified
  • Index process – The time when the indexer is running
  • Main controller – It gives tasks to the Index process

 

Magento Index process

Below you can see the flow chart of the Magento Index process:

 

Magento index flowchart

 

Indexing can be started by way of a Magento event and manually as well. During the index process, in the user interface, the data are read from the EAV tables, thus reindexing is not recommended only in special, justified cases.

 

Describing Magento Indexing

Catalog and product indexing is switched off by default with both Magento CE and Magento EE. To switch it on go to System -> Configuration -> CATALOG -> Catalog -> Frontend -> Use Flat Catalog Category and Use Flat Catalog Category lists and select YES.

After saving, you’ll be notified in the Magento notification area that a reindex is necessary.

 

Magento index switch on

The Magento notification area can be found in the admin panel, right below the menu.

 

How to run Magento indexing?

 

1) Magento admin

Go to System -> Index Management. Click th Select All link, select Reindex Data at the Actions option, then click Submit.

 

Magento index run admin

 

2) Shell script

Start a terminal, then go to the Magento source directory and give the following command:

php shell/indexer.php –reindexall

 

Magento index run shell script

 

You also have the possibility of running only one index if you run the indexer.php with the –reindex <indexer> parameter. For example, if you want to reindex catalog URLs, then run the following command:

php shell/indexer.php — reindex catalog_url

 

Magento index run shell script 2

 

If you set the info parameter with the indexer, then you will get a list of all the indexes and the index codes.

 

Magento index run shell script

 

+1 method: from PHP code

Run the following code for the total reindex:

<?php
/* @var $indexCollection Mage_Index_Model_Resource_Process_Collection */
$indexCollection = Mage::getModel('index/process')->getCollection();
foreach ($indexCollection as $index) {
    /* @var $index Mage_Index_Model_Process */
    $index->reindexAll();
}

If you want to update only one index, then the following code  is enough:

<?php
$process = Mage::getModel('index/indexer')->getProcessByCode('catalog_product_price');
$process->reindexAll();
}
instead of catalog_product_price insert the index name that you'd like to update.

 

 

How to speed up reading from Magento index table

It is possible to add MySQL table indexes to index tables. One way to do it is the manual method, e.g. in phpMyAdmin, but after a reindex these indexes will disappear because following every reindex, Magento deletes and creates index tables. So we need a more advanced solution.

In the example below we add indexes to a product index.

Let’s create a module and “subscribe to” the catalog_product_flat_prepare_indexes event in its config.xml in the following way:

<catalog_product_flat_prepare_indexes>
    <observers>
        <aion_catalog_product_flat_prepare_indexes>
            <type>singleton</type>
            <class>aion_catalog/observer</class>
            <method>catalogProductFlatPrepareIndexes</method>
        </aion_catalog_product_flat_prepare_indexes>
    </observers>
</catalog_product_flat_prepare_indexes>

You can see in the xml section above that before the product reindex, the catalogProductFlatPrepareIndexes method of the Aion_Catalog_Model_Observer class will be called.

At this moment the table is created, we only need to add the new indexes to the table:

 

/**
 * Add indexes to product flat table
 *
 * @param Varien_Event_Observer $observer observer
 *
 * @return void
 */
public function catalogProductFlatPrepareIndexes(Varien_Event_Observer $observer)
{
    /** @var Varien_Object $indexesObject */
    $indexesObject = $observer->getIndexes();
    /** @var array $indexes */
    $indexes = $indexesObject->getIndexes();
 
    /**
     * We add indexes to these fields for faster request processes
     */
    $addFields = array(
        'upload_date', 'news_to_date', 'special_price', 'special_from_date', 'special_to_date'
    );
 
    foreach ($addFields as $field) {
        $indexes['IDX_'.strtoupper($field)] = array(
            'type' => Varien_Db_Adapter_Interface::INDEX_TYPE_INDEX,
            'fields' => array($field)
        );
    }
 
    $indexesObject->setIndexes($indexes);
}

 

We can add other attributes to the $addFields array. Please not that it is not all column types to which you can add indexes.

 

Errors that my occur during indexing

It can happen that you see some indexes with a processing status for a long time in the Index Management menu. This means that PHP could not close the index_process_*.lock files in the var/locks folder. The easiest way to solve this problem is to delete the lock files.

Another common error appears when the flat table gets damaged and this makes indexing fail. In such a case, the damaged flat table can be deleted without a problem because when reindexing, Magento checks if the table exists or not and if not, it creates it.

The columns in MySQL has a maximum number of 4096, but in reality it is much smaller. It also depends on how many characters each column can store. Thus it can happen that the table cannot be created. This is a rather hidden error because you can only see in the admin panel that the table cannot be reindexed, but you will have to search for a reason with server settings.

If you encounter such a problem, it’s worth taking a look at the attributes – whether all of them are needed in the flat tables or not. If you manage to reduce the number and/or size of the attributes (e.g. using varchar instead of text), this problem can be easily solved.

Unfortunately, the “trickiest” error is when the index process halts. This can happen when memory or running time limit is low on the web server. You can resolve this issue by increasing memory to be used by PHP and extend runtime.

Another solution is to run indexing with a command which I described at “2. shell script “ in the “How to run Magento indexing?” section.

 

Disadvantages of Magento index

I don’t want to confuse anyone. Magento index is a very useful feature of Magento. But at the same time you need to know about its disadvantages as well. Here are some:

  1. It duplicates data. Since data are written to the EAV data structure in admin, but on frontend the data are read from the index table. Therefore every product data is duplicated in the database. If you do not pay attention to reindex, it can happen that you see different things on the user interface than in the admin area.
  2. It needs abundant resources. Magento indexing uses a lot of server capacity because it reads data from a lot of locations.
  3. It is easy to reach the maximum limit of MySQL column numbers. I’ve mentioned this in the previous section.

 

Summary

I hope I could show properly the possibilities in Magento index and also provided help in solving some common problems that may arise. If you need any help, we’d be happy to assist you. Feel free to ask any questions in the comments field.

 

 

Bigcommerce vs. Magento: Choose the better one for your business

What are we going to talk about?

  • Prices, expenses – different constructions
  • Appearance, design
  • Installation and use
  • Functions – where the competition is close
  • Marketing opportunities
    • SEO
    • Social media
    • E-mail marketing
    • Promotional features
  • Customizability
  • Support and community
  • Summary – which is good for whom?

 

Prices, expenses

Magento CE is an open-source code system that is available and installable free of charge – in case of Magento, more significant expenses will emerge rather if you want to substantially tailor the ecommerce store to your own image, if you want new functions, new appearance, and so on. A package specifically tailored to large companies is also available, the Enterprise Edition, to which you can subscribe for an annual fee of $18,000. However, this is not the solution for the smaller online stores or for the beginner e-merchants.

There is no free version in case of Bigcommerce, therefore the system is at disadvantage in this field. Their smallest, Standard package costs 30 dollars per month, and their plan for large companies, which is also called Enterprise, contains individualized prices.

In case of Magento you do not have to pay for the transactions by default (naturally the online payment service you use can define a certain fee, this is, however, independent from Magento), while in case of Bigcommerce you cannot avoid that. In case of their starter package, the Standard, 2.9% + $0.30 while in case of the Enterprise version 2.2% + $0.30 is payable per purchase.

 

Bigcommerce vs Magento pricing

 

There is no major difference in the field of online payment options, both systems provide the opportunity to integrate several dozens of local and global payment options, therefore it is highly unlikely that you will have problems integrating these into your ecommerce store.

In both cases, you will have to separate a certain amount from the budget for the hosting service, and naturally, it is the business that will define how strong hosting you will need.

 

Appearance, design

Bigcommerce offers plenty of free templates to make the ecommerce store more colourful, and they can typically be viewed and installed easily. You can find responsive themes among these that are optimized to smart devices, which is a great advantage in the field of search engine optimization and from the point of view of user experience. At the same time, it is worth being cautious, because not all appearances are basically like that.

 

bigcommerce vs magento intro page

 

Design in case of Magento is a more delicate issue. You can find free themes here as well, and the system of Magento is already mobile-friendly by default. At the same time, if you want to stand out from the crowd, you will need some kind of individual development.

Taking into account the fact that Magento is considered to be an especially complex system, individual developments are only worth having if they are done by professionals. This of course may use up some of the budget, however, experience shows that it is worth it, because you can gain a lot of functions and solutions thanks to it, to which you would not have access otherwise.

Obviously, you can find commercial edition templates for both systems, with which you may broaden functionality, however, a complete customization may require individual solutions that cannot be found among the downloadable themes.

 

Installation and use

Installation of the systems is not particularly complicated in either case. The online store of Magento can be installed and you can go live as a matter of fact within minutes, it is a fact though, that you may need significant fine-tuning after that in order to build an ecommerce store that operates in the desired way. Bigcommerce is somewhat at an advantage because there is a quick installation option (Quicklaunch) available, which quickly leads you through the process.

In the field of everyday use and simplicity, just like most ecommerce systems, Bigcommerce beats Magento as well.

User interface of Bigcommece is extremely simple and intuitive, even beginners do not experience difficulties finding the functions important to them.

Magento is an entirely different thing, its use requires greater competence. However, this is due to complexity, the great deal of various functions: Magento offers so many features and options that you will inevitably need some routine to be able to handle it. At the same time, you can find lots of training materials, tutorials online, which can help you understand the administrative interface.

 

Functions

In this field Magento totally beats the competition. This is because you can customize the system any way you please: you can set everything in a way so that you ensure the best user experience in the online store.

You can create as many products and product categories as you want, which would not really be special at all, but at the same time you can also freely modify the characteristics of the products: it does not matter at all what you are selling, you can define any kind of attributes, and with the help of the professional narrow-down search the users can quickly find the products perfect for them.

 

bigcommerce vs magento business growth

 

Magento also provides you the possibility of making and viewing reports of practically all activities and you can create exceptionally rich databases with its help: you can study the behaviour of the users, the purchasing habits, you can monitor which products or product groups perform better and so on.

Bigcommerce is not falling too far behind, it provides the most significant features for the webmasters among the systems which are not open-source. You have the possibility of filtered search here as well, the system provides you data for analytics on content, marketing, customers and products.

Management of the products in the system is quite simple, and it already rivals Magento, as it presents a great deal of features just like Magento. You can use individual settings for example when defining the price, you can combine products, create individual fields, and you can even attach videos, not only images, to individual products.

It is common in the two systems that the developers primarily thought of the ecommerce stores serving higher demand when they created them: they considered the online stores selling even several thousands of products, containing detailed product descriptions and are rich in attributes, having high traffic. Consequently, the most suitable choice for those who want to launch their first ecommerce store with only a few simple products, would be another system.

 

Marketing opportunities

SEO

Magento is remarkably well search engine optimizable, among others you can enter meta information about the individual products, product categories, you can enter individual URLs, which will all facilitate that you reach higher rankings in the search engine results. You even have access to Google Content API and you can view the search expressions that your target audience uses. Naturally, Google sitemap is also accessible for the system. Its only disadvantage is that it generates several individual pages every single time when narrow-down search is used.

Bigcommerce does not fall behind in this field either, it does not lack sitemap and robots.txt, you can change the URLs and the pieces of meta information, and so on. The score between the two systems is practically tied in this field.

 

Social media

Magento does not really participate in the race in this field, you cannot find built-in features in the system. At the same time, with the help of extensions and individual developments you can remarkably strengthen social marketing.

Bigcommerce on the other hand already includes such features by default, you can sell through Facebook with the help of a program called SocialShop, you can even activate the share button. At the same time, there is no such direct link to other services like Twitter or Pinterest.

 

E-mail marketing

None of the two platforms offer too much by default in this field, however, Magento wins even with the limited features. This is because you can find an interface in the system where you can integrate your already existing newsletter service (like MailChimp) and you can also view the subscribers, you can manage them or send letters to them. On the other hand, in case of Bigcommerce you cannot send out letters even after the integration, but you can create opt-in forms, welcome e-mails and check-boxes.

 

Promotional features

Bigcommerce allows you to make various price discount offers, promotions with time limitation and you can integrate the price comparing websites as well, thus assisting the customers in finding the most suitable product. Magento offers more than that, it is amazingly rich in such features.

The users can prepare a wish list, you can set different prices for the individual user groups, you can create cross-sell and up-sell promotions (installation of additional extensions may be necessary for this in some cases), you can offer relevant products or products that are frequently bought together with the given product, or you can even offer them in packages, and so on. Therefore, the balance tips strongly in favour of Magento.

 

Customizability

It is not the first time that we mention this: one of the biggest strengths of Magento is that every single tiny detail of it can be adjusted to your own special needs – since it is an open-source software application, you have several opportunities to do that. For example the enormous and enthusiastic developer community offers online hundreds of extensions and individual plugins, both free of charge and paid options are available.

 

bigcommerce vs magento ce

 

However, you can also decide to apply solutions that are completely individual: in such a case it is worth working together with a professional Magento developer team, because you can get remarkably good results like that – at the same time that will require some portion of your development budget.

Bigcommerce can present an extremely diversified appstore as a counterbalance, where there is a good chance that you will find something that you need. However, since we are not talking about an open-source code system, your possibilities are obviously more limited as well.

 

Support and community

Should you have any problems, you can also ask your questions directly from the developers of Magento, the real strength here lies in the developer community. You can ask your questions on several different forums from several thousands of professionals with competence in Magento if you have problems or if you are just curious about something.

Obviously, there is no such community behind Bigcommerce, however, there is a 24-hour daily support on the phone, in e-mail or through chat included in the paid service.

Magento provides a great deal of training materials and tutorials, so you can find a lot of these on the internet, while Bigcommerce tries answering the most frequently asked questions and showing how to operate the system on its own blog page.

 

Magento developer community

 

Summary

Magento is an already well-tried system that is specifically suitable for serving as the basis of ecommerce stores with higher traffic and larger supply. Many global brands use Magento as a basis for their online stores and all in all, it has shown a fair 25-30 percent market share for the last few years.

It is customizable up to a great extent and it has an extremely high number of features by default. Although, it may take time to find your way around them, you can still get a lot of help to succeed.

Bigcommerce is also a fair system, the use and the installation of which is simpler. It is falling behind in many fields concerning the number and diversity of the functions. At the same time, it is less complex and for that very reason it is much more recommended for those who have less expertise in the operation of ecommerce stores.

Price can also play a role in making the choice: while Magento CE is free of charge, occasionally you will have to spend on development, and Bigcommerce provides a stable system and support in exchange for the monthly fee, but at the same time individual development is not an option here.

Magento allows you bigger freedom and lets professionals do whatever they want, it charges a high price for that, while Bigcommerce is more of a “safe player”, thus it may be a good choice for those who are less of a free spirit.

 

Step by step guide for customer configuration in the Magento admin panel

Contents

 

 

 

Manage customers in Magento admin

 

Customer list

In the admin panel go to Customers –> Manage Customers menu.

 

Manage Customers Menu

 

Here you can see the customer list.

Items of the list (by default, in English):

ID: customer ID

Name: whole name of customer

Email: customer’s email address used for ecommerce store log in

Group: customer group

Telephone: phone number

ZIP: customer’s ZIP code

Country: customer’s country (if it is empty, it is so because there is no address assigned to the customer)

State/Province: customer’s state or province

Customer Since: time of registration

Website: which website is assigned to the customer (you see this when you have more than one Magento websites)

Action: action (modification button)

 

Searching (filtering) in the list can be done in the following way:

 

Manage Customers Grid Search

 

You need to enter the word or number to be searched in the field at the top of the list and then click the Search button on the right.

For list ordering you need to click on column names in the lists (if there is any that cannot be clicked, it means it cannot be filtered).

If you’d like to see the whole unfiltered list again, just click the Reset Filter button.

Above the list you can select pages. Next to it you can set the number of customers to be shown on a page.

 

Manage Customers Grid Pager

 

You can export the customer list in csv or Excel xml format.

You can see this option at the top central section. You can select the format type at Export to and then click the Export button. Here you always export the presently filtered list (if the list is not filtered, then the whole customer list is exported).

You can also execute mass actions, you can perform these from the Actions drop down menu on the right.

 

Manage Customer Grid Massactions

 

Select the customers (the ones you’d like to run the given “event”) by clicking the checkbox in the first column, and then select the desired action, finally click Submit.

 

 

Adding a new customer

Start adding a new customer by clicking the Add New Customer button on the right.

At first you see only two tabs: Account Information and Addresses

 

Fill in the following details on the Account Information tab:

Account Information

  • Associate to Website: here you set to which website you want to associate the users.
  • Group: which customer group the user should belong to
  • Prefix: prefix of customer name (optional)
  • First Name: First name or given name
  • Middle Name/Initial: (optional)
  • Last Name: Last name or family name
  • Suffix: (optional)
  • Email: email address, for customer login
  • Date of Birth: (optional)
  • Tax//Vat Number: (optional)
  • Gender: (optional)
  • Send Welcome Email: if active, a welcome email is sent to the customer
  • Send From: from which store view the email is to be sent (used with multi-language websites)

 

Password Management

  • Password: enter the password here
  • If Send Auto-Generated Password is switched on, a random password is generated and sent to the email address; in this case the Password field is ignored.

 

Manage Customer Create Customer AcInTab

 

Addresses tab:

You can create a new address by clicking the Add New Address button. The fields should be filled in the same way as on the Account Information tab and there are some additional fields as well:

 

  • Company: name of company (optional)
  • Street Address: street name and street number
  • City: city or other settlement where company is located
  • Country
  • State/Province: (optional)
  • Zip/Postal Code
  • Telephone: phone number assigned to the address
  • Fax: (optional)
  • VAT number: (optional)

You can add more addresses if you want to. In the address list you can find two checkboxes where you can set the default billing and default shipping address separately.

 

Manage Customer Create Customer AddressesTab

 

Next, save the user by clicking on Save.

 

Customer data overview and modification

For modifying customer data, click the Edit button.

On the left you will see several tabs. I am going to describe each of them.

On the Account Information and Addresses tab you can find data that can be modified, the rest display information.

 

Customer View

Here you can see a general view about the customer.

Personal information:

  • Last logged in: date and time of last login (if it’s Never, then he or she has never logged in)
  • Confirmed email: email confirmed or not (it has significance only if confirmation email is set to be sent after registration)
  • Account Created on: date of registration
  • Account Created in: where the customer account was created(admin or a store view is shown here)
  • Customer Group: which customer group the user belongs to
  • Default Billing Address: data of default billing address displayed here (if there’s any)

Sales Statistics: here you can see the total figure of all purchases the customer has made at the online store

Recent Orders: the 5 latest orders are displayed

Shopping Cart: the contents of the latest shopping cart is displayed here

Wishlist: items of the customer’s wishlist are displayed here

 

Manage Customer Edit Customer Customer view Tab

 

Account Information:

I’ve described it earlier at Adding a New Customer.

Addresses:

I’ve described it earlier at Adding a New Customer.

Orders:

Here you can see the orders of the customer.

 

Manage Customer Edit Customer Orders Tab

 

Billing Agreements:

Here you can see the list of billing agreements. With this function you can help the customer set some data assigned to certain payment methods, thus simplifying the checkout process as the user does not need to fill in payment data all the time. (For this, agreements with the payment service provider need to be made, not to be detailed here.)

 

Recurring Profiles (Beta):

This is a list of subscription based purchases (see description in this article: Magento Product Types Setup – The Ultimate Guide

 

Shopping Cart:

What the customer’s shopping cart presently contains. Here the admin user can delete items with the Delete button on the right.

 

Wishlist:

Here you can find the products on the user’s wishlist.

 

Manage Customer Edit Customer Wishlist Tab

 

Newsletter:

The sent out newsletters are listed here (given that the user has subscribed to the newsletters).

 

Manage Customer Edit Customer NewsletterTab

 

Product Reviews:

Here you can see the opinions and reviews that the customer wrote (including approved, pending and not approved ones as well).

 

Manage Customer Edit_Customer Product reviews Tab

 

Product Tags:

Here you can see the product tags the customer has created.

 

Manage Customer Edit Customer Product tags Tab

 

Deleting a customer

You can delete customers in the list at the mass actions (detailed earlier) or by clicking Delete Customer at customer data modification. Of course, all the information on the customer is preserved at the orders (the purchases will not be lost).

 

 

Managing customer groups

 

Customer Groups list

To see them, just click on the Customers -> Customer Groups menu.

 

Manage Customer Group Menu

 

Here you can see the customer list, there are 4 groups by default:

  • General – the most frequently used one
  • NOT LOGGED IN – this is used and displayed when you permit guest purchases in your ecommerce store and thus the guest shopper is placed in this group.
  • Retailer
  • Wholesale

 

Manage Customer Group List

 

Why are there customer groups and why do we use them?

Because it can happen that you want to offer different prices to different customers or you’d like a group to be able to get discounts for specific products etc.

 

Creating and modifying a new customer group

Click on Add New Customer Group on the right of the list.

If you want to make modifications, select a group in the list.

 

You need to fill in the following:

Group Name, e.g. AionHill Shoppers

Tax class

 

Manage Customer Group add Group

 

Deleting a customer group

Select a group from the list for deletion and open it as you would for modification, next click Delete Customer Group on the right. The shoppers belonging to this group are transferred to the default group, which is the General group.

 

Managing system configuration of customers

Go to System -> Configuration menu.

Then to Customer Configuration link on the Customers tab.

 

Manage Customer Settings Conf Tab

 

In the upper left corner you can select which website, store or store view is to be taken into account for the configuration.

Here you can set the following:

Online Customers Options

  • Online Minutes Interval: If left empty, the list in the Customers -> Online Customers menu is updated every 15 minutes by default.

 

Manage Customer Settings Customer Conf Tab Online

 

Account Sharing Options

  • Share Customer Accounts: Here you can set whether you allow inter-store purchases or not (e.g. you have 3 websites and if this value is set site by site then the shopper needs to register with each of them separately to be able to make purchases, however, if it is set to global, he or she can shop with only one user account in all three e-stores.

 

Manage Customer Settings Conf Tab Account

 

Create New Account Options

  • Enable Automatic Assignment to Customer Group: If set to YES, then additional fields will appear where you need to define which customer group the user will belong to after checking the tax number.
  • Default Group: Here you define the default group. The new shopper will be placed here after registration or the shoppers will be transferred to this group after deletion of their group.
  • Default Value for Disable Automatic Group Changes Based on VAT ID: like the first setting, this too is related to tax number check
  • Show VAT Number on Frontend: This setting also involves tax number check
  • Default Email Domain: This is used only if the administrator submits an order via the admin panel and does not fill in the email address.
  • Default Welcome Email: Template of default welcome email
  • Email Sender
  • Require Emails Confirmation: If set to YES, then after registration the customer will get a confirmation link and can activate his or her account by clicking that link
  • Confirmation Link Email: Template of confirmation link email
  • Welcome Email: Template of welcome email
  • Generate Human-Friendly Customer ID: If set to YES, a “nicer” customer ID will be generated.

 

Manage Customer Settings Create New

 

Password Options

  • Forgot Email Template: Template of forgot email address
  • Remind Email Template: Template of remind email modified by the admin user, to be sent out to the customer
  • Forgot and Reminder Email sender: the sender of the two above mentioned emails
  • Recovery Link Expiration Period: Expiration time window in which the customer can change his or her password after clicking the recovery link in the email
  • Require admin user to change user password: If set to YES, you’ll need to give your (admin) password to be able to change customer password

 

Manage Customer Settings Conf Tab Password

 

Name and Address Options

  • Number of Lines in a Street Address: how many lines to show when entering the address
  • Show Prefix: whether or not to show (and ask at registration) the prefix (optional / required)
  • Prefix Dropdown Options: prefix options should be separated by semi-colons without spaces (e.g. dr;mr), if left empty, the user can fill it in.
  • Show Middle Name (initial): whether or not to show middle name, if set to YES, it can be given, but it’s an optional feature
  • Show Suffix: whether or not to show suffix
  • Suffix Dropdown Options: same as with Prefix Dropdown Options but here it is for suffix
  • Show Date of Birth
  • Show Tax/VAT Number
  • Show Gender

 

Manage Customers Settings Name Address

 

Login Options

  • Redirect Customer to Account Dashboard after Logging in

 

Manage Customer Settings Conf Tab Login

 

Address Templates

  • Text: title template text which shows in emails and print views
  • Text One Line: this template text shows in the order process
  • HTML: this appears in several places (in admin at the orders, in admin at modifying customer data, on frontend at the customer addresses)
  • PDF: appears in PDFs of billing, shipping and refund
  • Javascript Template: appears in js templates (in admin when you add a new customer address)

 

Manage Customer Settings Conf tab Address

 

CAPTCHA

  1. Enable CAPTCHA on Frontend: Do you want to show security code on frontend? If yes, then the following fields appear:
    • Font: font type
    • Forms: select which forms to be used:
      • Create User: at registration
      • Login: at login
      • Forgot password: at forgot password
      • Checkout as Guest: at checkout as guest
      • Register during Checkout: at registering while in checkout process
    • Displaying Mode: type of display, i.e. when to show CAPTCHA
      • Always
      • After number of attempts to login: after a certain number of unsuccessful login attempts, if selected, the following field appears:
        • Number of Unsuccesfill Attempts: if set to 0, it will always appear

 

  • CAPTCHA Timeout (minutes)
  • Number of Symbols: how many characters the code should comprise (e.g. 4-5 = 4 or 5 characters will appear)
  • Symbols Used in CAPTCHA: what type of symbols to be used (Here you can give the characters from which the system will generate the code. You can use letters from A to Z, either small or capital, and numbers from 0-9. (e.g. ABCDEFGHJKMnpqrstuvwxyz23456789)
  • Case Sensitive: If set to YES, capital and small letters are distinguished, (e.g. AaY1 and if set to NO, it will accept the following code as well: aay1).

 

Manage Customer Settings Conf Tab Captcha

 

Managing customer tax classes

First, go to Sales -> Tax -> Customer Tax Classes menu in the admin panel.

 

Manage Customer Tax Menu

 

Here you can see the existing customer tax classes, there is one present by default, namely Retail Customer.

For creating a new customer tax class, click Add New on the right.

The form is really simple, you should only give the name of the class and save it.

 

Manage Customer Tax create Tax Class

 

You may ask where to use it.

At customer groups you can set this: which customer tax class should be assigned to which customer group. Why is it useful?

Because every country and state (in the US) can have different tax rules and figures.

At Tax Rules you can set which tax rule is applicable to which customer group.

To do that, click the Sales -> Tax -> Manage Tax Rules menu.

 

Manage Customer Tax Rules Menu

 

The location where you create or modify a certain rule will be the location where you can set the customer group(s) to which it will be applicable.

 

Manage Customer Tax Rules Edit

 

Please note: In this section I don’t detail tax information any further because it would take too long. Tax issues will be described in another article.

 

Managing customer reviews and tags

 

Customer reviews

You can find customer reviews in three places:

  1. Catalog -> Review and Ratings -> Customer Reviews -> All Reviews

Here you can find all reviews

  1. Catalog -> Review and Ratings -> Customer Reviews -> Pending Reviews

Here you can find all pending (not approved) reviews

  1. Customers -> Manage Customers -> Edit

When modifying data of a customer, on Product Reviews tab, you can see the reviews of the given customer.

 

How to approve reviews?

You can do this in either of the menus mentioned above (if you don’t know which user made a review, it is recommended to select the second menu, where you find the Pending reviews).

If you’d like to approve more reviews at a time, then you should select those reviews by using the checkbox, then on the right hand side select Update Status in the Actions drop down menu and finally set it to Approved. Of course, you can select Pending or Not Approved as well if you wish so.

 

Manage Customer Review Peding Mass Update

 

If you want to go through them one by one, go to the Edit link and set the Status to the desired one and save it. Here you can also overwrite the reviewer’s name and text.

 

 

Manage Customer Review Peding Reviews Edit

 

Products tagged by customers

This you can find in several locations as well:

  1. Catalog -> Tags -> All Tags

Here you can find all tags.

  1. Catalog -> Tags -> Pending Tags

Here you can find all pending tags.

  1. Customers -> Manage Customers -> Edit

When modifying data of a customer, on Product Tags tab, you can see the tags created by the given customer.

 

How to approve tags?

The same way as you approve reviews (mentioned just earlier).

If you want to go through them one by one, click the line of the tag and set the Status to the desired one and save it. Here you can also edit the tag, can check which product it applies to (by admin or customer), which customers created it.

 

Manage Customer Tags Edit Tag

 

This tag editing form can be accessed from customer data modification at the Product Tags section.

 

Managing reports about customers

Customer reports can be found in the following locations at Reports -> Customers:

  1. New Accounts: number of new accounts for the given period
  2. Customers by orders total: total sum of orders by customers for a given period
  3. Customers by number of orders: total number of orders for a given period (i.e. how many times the customers made an order, quite similar to the 2nd feature

 

Manage Customer Report Menu

 

How to update the reports? It goes the same way with all three.

First, select one of the menus.

Select or enter the data:

  • From: start date
  • To: end date
  • Show By:
    • Day – daily break-down
    • Months – monthly break-down
    • Year – yearly break-down
tips Let’s see an example:

Select the New Accounts menu. Enter from 01/1/2016 to 03/31/2016 with a monthly break-down. Click Refresh. See the result:

 

Manage Customer Report New Account Report

 

You can see that for January and February there was no new customer, but for March there are already five.

 

As you see, you can set a lot of things with your customers in Magento. I hope this article proved to be useful to you. May you have any questions, please leave a comment below or contact us.

 

 

osCommerce vs. Magento: Which ecommerce CMS should I choose?

Topics that we are going to discuss below:

  • Prices
  • Installation and use
  • Customizability
  • Appearance, design
  • Updates, communities, support
  • Advantages and disadvantages: summary
    • Briefly about Magento
    • Briefly about osCommerce
    • Verdict – for the final decision

 

Prices and costs

Both Magento and osCommerce are systems of open source code, which means you do not have to pay to be able to download and install them. In addition, this is also advantageous because the developers can freely work on them, thus creating extensions to them and various modified versions of them.

The thing that you definitely have to take into account is the price of the hosting – in both cases, this depends on how big traffic you are planning with, how significant the online store is that you want to operate, so there is no difference between them in this respect.

 

magento oscommerce costs

 

Of course a commercial edition of Magento, Enterprise Edition, is also available, specifically planned for the needs of large companies, which can presently be used for an annual subscription fee of USD18,000. However, this has obviously been created for the global brands. Use of the Community Edition is totally free of charge.

osCommerce is a simpler system, it is even easier to make individual developments to it – if you want to completely transform Magento in a way that it meets your needs (or rather the needs of your target market), you will most probably need the assistance of professional developers, which will cost you money. Individual developments are of course worth the investment in the long run, you still have to take into account the budget, though.

 

Installation and use of Magento and osCommerce

Bringing the Magento online store to life is a complicated process, but the installation itself involves no particular difficulties. Installation of osCommerce is simple as well.

During utilisation it becomes clear that Magento is a more complex system: it was planned for more significant needs, for ecommerce stores with higher traffic, with a great deal of various features and options. As a consequence, the user interface itself is much more complicated as well, understanding it requires certain experience.

 

magento vs oscommerce sell online

 

This is somewhat counterbalanced by the fact that a great deal of training material is available, from which you can learn the masterstrokes, and you can also ask your questions from a quite sizeable and enthusiastic community – which latter one we will soon describe in detail.

OsCommerce is much more user-friendly, even those can relatively easily learn how to use it, who have never managed an online store before.

A great strength of Magento is that you can manage more than one ecommerce stores simultaneously from the same administrative interface thanks to it. OsCommerce does not offer such a possibility. Consequently, a business that targets more than one customer groups simultaneously, that wants to sell its different products separately, undoubtedly benefits more from Magento, considering the two alternatives.

 

Customizability

Magento is unbeatable in this category. It contains a large number of functions that are either not available with other ecommerce systems or they are only available in the form of different extensions (many times paid versions).

 

magento-custom-solutions

 

Promotional features like for example coupon deals are definitely worth mentioning, since sales within the online store can be increased quite effectively with their help: you can combine and offer certain products together, you can create special deals tailored to given groups of users, you can introduce discounts with time limitation, you can promote individual product groups and so on. You can even provide the possibility for the users of comparing the individual products.

The product search feature is outstanding as well, since you can define the attributes of the individual products perfectly freely in the system of Magento. You may create any kind of characteristics that you want, so this way the system is capable of adapting without difficulties to any kind of product range, even to the most diverse ones.

OsCommerce includes a much weaker set of tools: although you can find a series of functions in it, and you can further broaden the selection with extensions as well, it cannot get anywhere near Magento in this field. Among others it lacks coupon deals, discounts, which can be considered as a huge minus if you are searching for a flexible ecommerce system. On the other hand, it has a “what others have purchased” function similar to that of Amazon, which may compensate a little for this shortcoming.

 

Appearance and design

This “round” is won by Magento too. Because practically every single tiny detail of Magento can be transformed and customized – of course, as it is a complex system, you will need professional assistance to do that, but it is worth investing both energy and money in that. Obviously, nobody wants their ecommerce store look exactly like everybody else’s, that it is indistinguishable from those of the competitors. The risk of that is still there even if you change the standard appearance to a theme available free of charge or to a paid one. It is uniqueness that helps you avoid that.

 

magento vs oscommerce add ons

 

Of course, you have the possibility of modifying the design in case of osCommerce as well, however, experiences show that this is a quite complicated and difficult task.

Therefore it is a fact that no matter which of the two systems you choose, you will by all means need to hire a developer, unless you are a professional at the modification and the encoding of similar systems, and in web design. On the other hand, a Magento developer is easier to find.

 

Updates, communities, support

Magento is considered to be the more modern system, because a new system update (and additional, specifically security updates) is released generally every month and it can be said that it completely meets recent user needs – it is fully search engine optimizable, it can be made responsive and so on. OsCommerce is certainly not regarded as an outdated system either, however, it is true that updates are released much less frequently, and the developer community works with lower intensity as well, than in case of Magento.

 

magento community

 

In case of osCommerce Support is primarily built on the community. Of course the platform has its own developers as well, but even their official website recommends hiring professionals for the more significant problems. In addition, you have the possibility of looking for solutions for your problems on the forum, and you can also live chat with individual members of the community.

 

oscommerce-support

 

The situation is similar with Magento as well: you are able to contact the company’s own developers, however, the real power lies within the enormous and active developer community.

 

Advantages and disadvantages of Magento and osCommerce: Summary

 

Briefly about Magento

It is a system that was not planned for those wishing to fill their first small online store with a couple of dozens of products, but it was planned rather as an ecommerce software application that is able to respond even to the most creative individual needs.

Magento is recommended for companies that already have established markets, with predictable and regular traffic, and which can definitely finance a professional online store.

Although the system is complicated, it offers an outstanding amount of settings options that both facilitate improvement of the user experience and can also increase sales.

The system supports several dozens of payment options, so you will not have difficulties either with the domestic or foreign transactions, integration is possible without problems, and the system naturally stores the data securely encrypted.

 

magento community edition

 

It may be a problem that the (otherwise well structured) user interface with the great deal of features and settings options may be perplexing for the beginners. And you will definitely have to turn to a professional when it comes to development – Magento can be exceptionally well extended, however, a thorough knowledge of the system is necessary for that.

 

Briefly about osCommerce

OsCommerce is a reliably running, stable system with a great deal of available extensions and plugins. It is an old and well-tried system that is not at all beaten by Magento when an ecommerce store with a more significant performance is necessary, unlike the majority of the systems that are available free of charge.

 

All in all, you will most likely have less expenses with the use of osCommerce, but it does not contain appropriate cross-sell and up-sell options or promotional features. It is updated slowly, it is difficult to modify and it is overall lagging a bit behind when it comes to the latest solutions.

 

Verdict

It can be impartially said that for those who want to operate an even somewhat significant online store and are looking for a reliable, secure system that – though with the involvement of expenses – is transformable, customizable and flexible, Magento is the better choice. OsCommerce has become a bit aged by now and it is a good choice mainly for those who want a simpler but reliably operating ecommerce store and who do not wish for diversified features for boosting sales.

 

The basic guide to Magento layout development

Structure of layout

Layout definitions are always connected to a given extension. They can be set in the extension’s config.xml file on the customer page as the following:

 <frontend>
<layout>
<updates>
<aionmodul module=”Aion_Modul”>
<file>aion_modul.xml</file>
</aionmodul>
</updates>
</layout>
</frontend>

And also on the admin page:

<adminhtml>
<layout>
<updates>
<aionmodul>
<file>aion_modul.xml</file>
</aionmodul>
</updates>
</layout>
</adminhtml>

The tag within the <updates> tag should be a unique name.

You can see in both cases that the name of the layout file should be defined in the <file> tag. The layout files are to be found in the app/design/frontend/[package name]/[theme name]/layout, and the app/design/adminhtml/[package name]/[theme name]/layout directories.

In the XML file, it should be defined between the following tags which layout handler the command (tag) should consider.

<layout version=”0.1.0″> 

and

</layout>

 

 

Function of layout handle

Block definitions are always located within a well defined handle. A layout handle designates a collection of more blocks with a name. The default layout handle is added to every page in the given scope. The main page is built up according to the following layout handles:

  1. default
  2. cms_page
  3. STORE_default
  4. THEME_frontend_rwd_default
  5. cms_index_index
  6. page_two_columns_right
  7. customer_logged_out
  8. cms_menu

 

Indeed, the default handle has also been given to this page. The cms_page, cms_index_index and cms_menu handle also loads which means that the main page is a CMS page too. The same list looks like this on a login page:

  1. default
  2. STORE_default
  3. THEME_frontend_rwd_default
  4. customer_account_login
  5. customer_logged_out

 

The 4th handle defines that at the moment customer front name, account controller and login action serve the page. In the case of the main page, these are cms front name, index controller and index action.

 

layout magento

 

Function of blocks

In the above examples we have touched on blocks marginally, but now let us see in more detail what blocks mean in Magento. Below you can see a list of the different types of Magento blocks:

  • core/template: This type of block is responsible for rendering templates. The majority of blocks belong to the core/template type.
  • page/html: This block type is derived from a core/template block. It defines the parent block. Every other block is a child block of page/html block.
  • page/html_head: This block type is responsible for the HEAD section of an HTML page. Thanks to it, we can define JavaScript, CSS etc. items.
  • page/html_header: It is in charge of displaying the header of the page. Here we find the logo of the ecommerce store, top links etc.
  • page/template_links: This block type is used for creating link lists. Links are displayed in the header and footer by default with the help of the page/template_links
  • core/text_list: Some page elements (content, left sidebar, right sidebar) are displayed with the core/text_list block. When these block types are rendered, all their child blocks are rendered automatically. An important feature of core/text_list block types is that they do not have templates.
  • page/html_wrapper: This block type can be used for wrapping other elements. It uses <div> tag by default.
  • page/html_breadcrumbs: This block type displays breadcrumbs on the page.
  • page/html_footer: This block type displays the footer where you can find copyright details, footer links etc. by default.
  • core/messages: This block type shows the messages. A message can be an error, success or warning type message.
  • page/switch: This block type displays the drop down language selection options.

 

Of course, these block types are only the default types. There can be others created according to the custom design theme or extension requirements.

Each block must have a type and name. Block template and alias are not necessary.

With a reference tag you can refer to existing blocks. If you already have a larger block and you want to display elements in it from several layout files, then you need to implement a reference tag. Here is an example:

 <reference name=”right”>
<block type=”core/text” name=”right.text”>Bal oldalt megjelenő szöveg</block>
</reference>

 

We gave a new block, named right.text, to the block called “right”.

This is a very useful method when you would like to modify an existing page in your own extension. We can also remove an already added block. Here is an example:

 <reference name=”right”>
<remove name=”right.text” />
</reference>

 

We removed the “right.text” block, created in the above example, with the remove tag.

If we don’t know the name of the given block or which template manages displaying, then it is very useful to switch on “template path hint”. You can do this by setting the System -> Configuration -> Developer -> Template Path Hints option to YES. Please note that this setting cannot be set “globally”, it can only be set in website view. If you want to see the classes of the blocks, then in the same menu set the Add Block Names to Hints option to YES. If your website is live, be careful because your visitors may be taken aback seeing your page like this:

 

magento layout Template Path Hints

 

 

You can see the template path on the left and the block’s name on the right.

It is also possible to have the template path hints shown only to you. In this case you insert your computer’s IP address in the Allowed IPs field in the System -> Configuration -> Developer menu.

 

Management of CSS and JavaScript files from layout

Many times it is needed to implement external resources (CSS and JavaScript) on your page. This can be easily done from layout XML with the following tag:

 <block type=”page/html_head” name=”head” as=”head”>
<action method=”addJs”><script>prototype/prototype.js</script></action>
</block>

<block type=”page/html_head” name=”head” as=”head”>
<action method=”addCss”><stylesheet>css/widgets.css</stylesheet></action>
</block>

 

In the first example we insert prototype.js from the js directory, in the second example we insert the widgets.css file from the skin directory.

 

 

Using layout update

You can add a new handle to an existing one with the update XML tag. Let’s suppose we’d like to add a hello layout handle to the content block of the cms_index_index layout handle. This can be done the following way:

 

<cms_index_index>
<update handle=”hello” />
</cms_index_index>

 

Here, all modifications of <hello> handle can be valid for the main page (<cms_index_index> handle). This comes in handy if you want to display a contact form on several pages, since you don’t have to insert the block definition of every contact form on each of the pages. It is enough to insert it in a new handle and load that handle on the specific pages with the update command (tag).

 

Typically, in case of new design themes, developers do not refer to existing layout files in the local.xml, but copy and paste them, as they are, to their design theme directory. This “improper” method is not recommended at all, because if an update is issued which would affect the layout files as well, this update will fail, as the files will not be overwritten in the new design template.

I admit that the solution I recommend is a little more complex and may not be applicable to every case in this field, but it still is more advanced, especially in the long term.

 

SUMMARYAs we could see from the examples, layout XML is an essential part of Magento. That is why it is important to know it thoroughly. I hope this short guide will be useful for many Magento developers. Should you have any questions, we will be happy to give you an answer.

 

 

VirtueMart vs. Magento ‒ Which is better?

What are we going to talk about?

  • Prices and expenses
  • Installation and use
  • Customizability
  • Analytics
  • SEO
  • Community and support – where can you turn to?
  • Let’s sum it up
    • What is Magento capable of?
    • What is VirtueMart capable of?
  • VirtueMart or Magento? Which one should you use?

 

magento vs virtuemart

 

You can observe a great deal of fundamental differences between the two systems, the simple reason for which is that Magento was originally made to be an ecommerce system: its primary aim is to have online stores built on it, in particular those that require higher performance because they often operate with several thousands of products and high traffic.

On the other hand, Joomla! is a CMS, which means it was born as a Content Management System. VirtueMart is no other than the extension of Joomla! that also has ecommerce functionality.

Let us see which of the two systems, that have followed fundamentally different paths, may be appropriate for the creation of a new ecommerce store.

 

Prices and expenses

An aspect, right at the beginning, where there is basically no difference between the two systems: both Magento and VirtueMart can be downloaded free of charge, at least their simplest versions can be. You can take this for granted, as both online store software applications are of open-source code.

 

magento virtuemart costs

 

In case of Magento it is primarily Magento Community Edition that may be a good choice for those operating under the large company level: it is a free of charge system, to which both free and paid extensions can be downloaded. Expenses will emerge rather when you want to develop the capabilities of the system, or to customize its appearance. Because in this case you will need to have individual developments made by a third party.

You can do the same thing in case of VirtueMart as well, and the software has such unique, further developed versions that are available for purchase by default as commercial editions.

You have to take into account the price of the hosting service in both cases, and it is also worth mentioning that Magento has a version planned specifically for the needs of large companies, the Enterprise Edition, which can presently be used in exchange for an annual subscription fee of 18 thousand dollars.

 

Installation and use

Installation and launch of VirtueMart is a simple process which can be done relatively smoothly even by beginners. Installation of Magento is not particularly complex either, although it may require some preparedness. On the other hand, launch of an operating ecommerce store may be perplexing for those who have not yet worked with a similar system before.

Great power in this case does not go together with great responsibility but with high complexity. Magento is an extraordinarily powerful system capable of creating giant and complex ecommerce stores – the interface is obviously packed with features, the use of which you have to learn.

 

Customizability

What is missing from most ecommerce software applications is common in the two systems: the frontend is diversely customizable, it can be tailored to your needs. Joomla! is at advantage being a more simple system thus its design can be more easily modified and it can be more simply extended with extra functions. Magento on the other hand offers you a more professional solution, it outstrips its competitor in the field of shopping cart, in other words, the purchasing process.

It is a built-in feature in case of Magento that you can modify each product or product category almost any way you want to: you may apply countless different attributes to the products, which the users can search by filtering.

Much more important than this are the diverse promotion possibilities: you can either offer discounts within a certain period of time, offer those for more precisely defined user groups, or even provide certain products at a different price if they are bought together. You can advertise certain products together with those that are regularly purchased together. The number of possibilities is almost higher than what a single online store can take advantage of.

 

Analytics

Being able to create quite detailed reports is a standard feature in case of Magento:  you can study how certain products or product groups perform, how the users use your ecommerce store, what kind of behavioural patterns you can register. Joomla! on the other hand provides you very restricted possibilities, you have to apply various extensions to be able to carry out more complex analytics.

 

SEO

The system of Magento can be actually well optimized, you can create individual URIs and you have other options as well, at the same time, this is not a content management system – so these are considered rather like extra features in this case. Joomla! on the other hand is a CMS, so VirtueMart that was built on its basics can be extremely well optimized as well.

 

magento virtuemart seo

 

If you want a system that is fundamentally well search engine optimizable, actually there is no major difference between the two platforms in this respect. If SEO is a significantly important aspect of your strategy and everything is subordinated to that, the balance tips in favour of Joomla!.

 

Community and support

Both platforms have fair-sized communities behind them: a great deal of developers are engaged in making different extensions and plugins to the systems of Magento and Joomla!. Consequently, this means that should you have any kind of problem, you have many places to turn to, you will easily find a platform where you will be able to contact the competent professionals.

Furthermore, you can easily find extensions as well, both free and paid versions –, which is useful in case of both systems, although in case of Magento it is many times more worthwhile having individual developments made.

 

Let’s sum it up

 

What is Magento capable of?

The Magento system is modern and is continuously developing, there is a huge developer community behind it that provides a great deal of free of charge and paid extensions for the users. The development is continuous, the official company is constantly working on it as well so that the system meets the most recent requirements. In addition, the webmaster can hire a professional development team in order to completely customize the open source code software.

 

magento community demo

 

Being versatile is another advantage of the system: thanks to it you can modify the frontend any way you want to, by which you can ensure the best user experience. Also, the available settings in the administrative interface are so diversified that practically no other system that is available free of charge can compete with.

Of course Magento has relative disadvantages as well. One of these for example is that you will need a stable hosting service, because Magento is a resource-intensive system. This is particularly true when you are working with a large number of products and with high traffic, in which case you would need strong hosting for your services – the difference is that Magento is capable of handling online stores of any size.

Complexity may be a disadvantage if it is a beginner who starts creating an ecommerce store. Magento has an amazing amount of setting options and features, which is even further enhanced by the customization possibilities, extensions and individual developments. Therefore experience is necessary for the handling of Magento, it is less recommended for the creation of your first online store because the inexperienced webmaster will likely have difficulties finding his way around the system.

For this very reason you will probably need professional assistance as well, developers who will forge Magento ideal for you – for which job you will need to have a separated budget.

 

What is VirtueMart capable of?

The most significant advantage of the extension of Joomla! compared to Magento is that it is simpler. Even users with a lower level of knowledge may be relatively simply able to manage the system, to search for and to install extensions. Typically, when using VirtueMart it is unnecessary to hire a separate developer because there are available extensions well applicable for the simpler needs, and also, there are such VirtueMart variants that have adequate functionality.

 

virtuemart product page

 

VirtueMart is at advantage in the field of content management as well, which is not a big surprise, since Joomla! is a content management system by default. Thanks to it, you can easily extend the online store with a blog, a guest book, a forum or any other interfaces focusing on content. Also, being able to display content more easily will facilitate SEO as well.

Its disadvantage is that the pace of its development is quite slow, that it has difficulty keeping up with others, as well as the lack of more developed functions from the basic system. You will have access to more significant ecommerce store functions only if you use its commercial edition versions, and there is a good chance that you will need various extensions to these as well.

 

VirtueMart or Magento? Which one to use?

What is the final verdict? That both systems fundamentally work well, however, they do not satisfy the needs of the same people.

According to this year’s February survey of Aheadworks, Magento CE has a 25% share on the ecommerce market of the one million most popular websites based on the data of Alexa, while the Enterprise edition made for large companies, available for an annual subscription fee of 18,000 dollars has another 4.5% share. In contrast, the share of VirtueMart compared to this is only 3.5% – which of course means that it is still considered to be one of the most popular systems (to be precise it is in the 6th place).

VirtueMart is a simple, easily manageable and quick system, however, many functions, which are considered as standard features in Magento, are missing from it. Magento on the other hand is a more massive, more complex system that requires a higher energy input.

Consequently, those who wish for a simple solution, who are launching an online store of a smaller size, who would like to sell products in addition to content publication or are launching their very first ecommerce store, may take more advantage of Joomla! VirtueMart.

However, for those who would like to create a major, complex professional online store that can be customized and optimized to the extremes, that has several hundreds or thousands of products and is planned for a high traffic, Magento CE may prove to be the perfect choice.

 

 

How to implement extremely fast custom indexing in Magento?

We display a part of the data, located in the database, to the user unprocessed, i.e. in a raw format, other data we display processed, and there are also data that we do not show at all. The data should be stored decomposed into the smallest sections possible. This is one of the basic conditions of database normalization, which determines that one column of a database table represents one basic value.

A result of a normalized database is storing information efficiently, but it also slows down processing and displaying. In the case of a non-normalized database anomalies will occur, so normalization is simply a must. However, we’d still like to display data to the user fast.

Solution: we organize the data into a joint table, from which we can display the data without processing. The table containing the collective data is the flat table and the procedure which manages it is indexing. In this article we introduce the aspects with which, using Magento’s framework system, we can speed up processing and displaying without compromising on database normalization.

 

This article includes the following topics:

  • Anomalies of a non-normalized database
  • Requirements related to the data indexer
  • Event oriented indexing
  • Indexing in Magento
  • Summary

 

magento indexing flat table developer

 

Anomalies of a non-normalized database

 

We are going to touch on the reasons and consequences of anomalies without describing how to handle them.

A prerequisite of a normalized database is that all the columns of the table, i.e. every element of the record, represent one basic value each. There must not be identical rows and the order of rows should not refer to any information.

 

Three types of anomaly can occur in the case of a non-normalized database:

  1. Modification
  2. Insertion
  3. Deletion

 

  1. A Modification anomaly occurs when an attribute is present in multiple tables. In this case, a modification needs to take place in several locations. If it does not take place that way, our database will be inconsistent.
  2. Insertion anomaly occurs when, because of a missing piece of information, we cannot insert a row. The result of this is loss of information.
  3. If we delete data that we would still need, it is a case of Deletion anomaly. Here too, loss of information is a consequence.

In order to avoid anomalies, we need to normalize our database according to database normal forms.

 

Indexer requirements

 

The task of the indexer is to speed up data display. But, as we could see above, the indexed table does not contain basic data but processed data. Thus it will fail on a basic level in a normalization test. Therefore it needs to match certain requirements.

 

The main requirement is the following:

  • If we delete a flat table from the system, is should not cause any anomaly.
  • The system should work even without flat tables. -> Flat tables are not part of the system.

 

The first requirement can be met if only the indexing procedure manages the table and we delete the table before every indexing.

What happens if we have deleted such data that would be needed?

The answer is trivial. We cannot delete such data, the flat table is not part of the system, it only helps to display them. The system should operate even without it.

tips Example: We compose the flat table, but we delete a record in the meantime, which is not needed. In this case, the data in the flat table are not up-to-date anymore. When we reindex, there will be data that are not needed anymore. If we do not delete the flat table, then we should check if the given values are needed or not. This would be a lengthy and complex process. Deleting and then rebuilding the whole table is the best solution. This notion will be supported by other reasons to be mentioned later.

Larger speed will be a result because only those data are included in the table that are needed. But these data need to be managed and provide the most up-to-date state. The most important aspect of the system is speed and efficiency. However, there can be huge variances between the task management efficiencies of the sub-systems.

 

Common solution:

magento indexing process flat table

1. Illustration of indexing process

 

The graph above includes the following steps:

  1. PHP requests the records to be indexed, from several tables and through a number of models.
  2. Next, MySQL sends the requested data.
  3. PHP processes the records with the help of cycles, often with multi cycles.
  4. PHP sends back the records one by one.
  5. MySQL updates them.

 

Pro: Simple and clear logic.

Con: Very slow. It is not suitable for meeting requirements related to flat tables. There are certain systems where it provides satisfactory performance, but here it is not an option.

 

Optimal solution:

optimal magento index process flat table

2. Process of indexing

 

 

Optimized steps:

  1. With the help of models, PHP composes the SQL SELECT which is returning the flat table
  2. MySQL executes this SELECT and inserts the created table in the database

Pro: Very fast, in some cases a 30-fold increase in speed. Eliminates loss of communication between the two systems. Satisfies the requirements.

Con: The request process is often very complex. It can happen in rare cases that MySQL is not capable of creating the processed data. In this case an optimized hybrid solution is to be used which is case-dependant.

 

Event oriented indexing

 

We can initiate the indexing process manually possibly also with the help of cron. In this case a total reindexing is necessary since we do not know which records are not up-to-date. It also presents a dilemma that how often the reindexing should be run.

Total reindexing is unavoidable since it is important in terms of speed that only relevant data are present in the table. On the other hand, running it after every modification is costly and thus we lose more than what we’d gain. To avoid this, such processes should be created that index certain rows only. Implementing this is quite simple because we can filter the records in the WHERE condition of the SELECT request based on the given condition.

We structure the database tables in such a way that when inserting, MySQL will know automatically if a record is new one or an existing one that just needs to be modified.

 

Two things need to be defined:

  1. When should the index be run?
  2. Which records should be indexed?

 

Reindexing should be run if a data is changed in the source table and should be run in those records where the data is located.

Implementation: We define events, and when they occur, we know that some data have been changed in the source table. If the event occurs, then we run the indexing for the given record.

 

Indexing in Magento

 

Creating a Flat table

A flat table should be created in such a way that when inserting, MySQL can identify whether there is a new or an existing record. Unique indexing is a solution for that.

config.xml: We need to give a name to our table.

<entities>
    <index_table>
        <table>custom_index_table</table>
    </index_table>
</entities>

 

We register the indexer:

<global>
    ......
    <index>
        <indexer>
            <some_key>
                <model>module/model</model>
            </some_key>
        </indexer>
    </index>
    ......
</global>

 

Code: We add the unique indexes in the installer.

$table->addIndex(
    $installer->getIdxName(
        'your_namespace/your_table',
        array(
            'column1',
            'column2',
            'column3',
        ),
        Varien_Db_Adapter_Interface::INDEX_TYPE_UNIQUE
    ),
    array(
        'column1',
        'column2',
        'column3',
    ),
    array('type' => Varien_Db_Adapter_Interface::INDEX_TYPE_UNIQUE)
);

 

With this, we avoid to have records in multiple locations in the table.

 

Creating the indexing process

We create the actual functions in a helper.

We need to implement 3 functions:

  • runReindex($id) – private
  • reindexAll() – public
  • reindexById($id) – public

 

Runindex method

First we set the database adapter:

$resource = Mage::getSingleton('core/resource');
$adapter = $resource->getConnection('core_write');

 

Then we request the model to which we join the other tables:

$collection = Mage::getModel('namespace/model')
    ->getCollection()
    ->removeAllFieldsFromSelect()
    ->removeFieldFromSelect('id');

 

We remove all the columns of SELECT so that we can adjust these to the index table. Then we join the tables, from which we still need data.

Example: ORDER ITEM join:

$collection->getSelect()->joinLeft(
    array('order_item' => Mage::getSingleton('core/resource')->getTableName('sales/order_item')),
    'order_item.order_id = main_table.order_id',
    array()
);

 

Next we define the column names and column order structure equivalent to the flat table.

$columns = array(
    'column1',
    'column2',
    'column3',
);

$collection->getSelect()
    ->columns('wishlist_item.product_id AS column1')
    ->columns('GROUP_CONCAT(customer_id SEPARATOR ",") AS column2')    ->columns('SUM(wishlist_item.qty) AS column3');

 

We create the request providing the flat table:

$select = $collection->getSelect();

 

We run the request and insert it in the table:

$sql = $adapter->insertFromSelect($select,
    Mage::getSingleton('core/resource')->getTableName('namespace /custom_index_table'),
    $columns,
    Varien_Db_Adapter_Interface::INSERT_ON_DUPLICATE);

$adapter->query($sql);

 

As we can see, communication is minimal between the two systems. PHP sends the request which returns the flat table. MySQL runs this and inserts it in the database.

 

ReindexById method

We need to filter the records of SELECT:

$collection->getSelect()->where('id = '.$id); 

 

ReindexAll

We empty the index table. We request the identifiers of all the records and call the runReindex($id) method.

 

Event dispatch

<?php
class Namespace_Model_Model extends Mage_Sales_Model_Order_Item
{
    const ENTITY = 'namespace_model_model';

     /**
      * Before Delete
      */
     protected function _beforeDelete()
     {
         parent::_beforeDelete();

         Mage::getSingleton('index/indexer')->logEvent(
             $this, self::ENTITY, Mage_Index_Model_Event::TYPE_DELETE
         );
     }

     /**
      * Before Save
      */
     protected function _beforeSave()
     {
         parent::_beforeSave();

         Mage::getSingleton('index/indexer')->logEvent(
            $this, self::ENTITY, Mage_Index_Model_Event::TYPE_SAVE
         );
     }

     /*
      * After Save Commit
      */
     protected function _afterSaveCommit()
     {
         parent::_afterSaveCommit();

         Mage::getSingleton('index/indexer')->indexEvents(
             self::ENTITY, Mage_Index_Model_Event::TYPE_SAVE
         );
     }

     /*
      * After Delete Commit
      */
     protected function _afterDeleteCommit()
     {
         parent::_afterDeleteCommit();

         Mage::getSingleton('index/indexer')->indexEvents(
             self::ENTITY, Mage_Index_Model_Event::TYPE_DELETE
         );
     }

 }

The data can change in two cases: modification and deletion. Thus these events need be observed. As we can see, Magento differentiates between index events. It is up to the programmer which events should be monitored by the indexer.

If the indexer wants to observe an event which is not dispatched, and can be found in the Magento Core, then the original class should be overwritten. This class should be derived from the original class.

 

Implementing the Magento Indexer

The indexer class, which monitors and runs the indexing processes, should be created in the model directory of our module. This class should be extended from the Mage_Index_Model_Indexer_Abstract class.

class Namespace_Model_Indexer extends Mage_Index_Model_Indexer_Abstract

 

Next, observation of events is needed, this is declared in a class array:

/**
 * Index matched Entities array
 *
 * @var array
 */
protected $_matchedEntities = array(
    Namespace_Model_Model::ENTITY => array(
        Mage_Index_Model_Event::TYPE_SAVE,
        Mage_Index_Model_Event::TYPE_MASS_ACTION,
        Mage_Index_Model_Event::TYPE_DELETE
    ),
);

 

We have declared the model’s events a little earlier. We can see in the code above the function of the ENTITY constant value to be found in the class. With this we identify the model. The abstract methods need to be created:

/**
 * @return bool
 */
public function isVisible()
{
    return true;
} 

/**
 * Retrieve Indexer name
 *
 * @return string
 */
public function getName()
{
    return Mage::helper('namespace')->__('Custom indexer');
} 

/**
 * Retrieve Indexer description
 *
 * @return string
 */
public function getDescription()
{
    return Mage::helper('namespace')->__('Reorganize custom flat data');
} 

/**
 * Rebuild all index data
 */
public function reindexAll()
{
    Mage::helper('namespace/indexer')->reindexAll();
}

 

Event recognition and management

We can carry it out by creating the _registerEvent method.

/**
 * Register indexer required data inside event object
 *
 * @param   Mage_Index_Model_Event $event
 */
protected function _registerEvent(Mage_Index_Model_Event $event)
{
    $dataObj = $event->getDataObject();
    if($event->getType() == Mage_Index_Model_Event::TYPE_SAVE){        $event->addNewData('id, $dataObj->getId());
    }elseif($event->getType() == Mage_Index_Model_Event::TYPE_DELETE){
        $event->addNewData('id, $dataObj->getId());
    }
}

 

We detect what kind of event has happened and then add the data necessary for indexing. In our example, it is the model identifier since we index based on it. Managing events can be done uniquely,  however, and may need different data.

 

Running indexing

 The actual indexing takes place through the _proccessEvent method.

/**
 * Process event based on event state data
 *
 * @param   Mage_Index_Model_Event $event
 */
protected function _processEvent(Mage_Index_Model_Event $event)
{
    $data = $event->getNewData();
    if(!empty($data['id'])){
        Mage::helper('namespace/indexer')->reindexById((int)$data['id']);
    }
}

 

SUMMARY

Optimizing speed is usually among the most important aspects with any system. (An exception is banking applications where safety is the only important consideration.) Flat tables can provide fast display, which is normally very much appreciated by our users. Using them is recommended with complex entities where information is allocated to a huge number of tables.

Since a traffic or capacity bottleneck is caused by the database segment, the problem needs to be tackled here as well and communication between the segments has to be minimized. The advantage of using flat tables is speed which makes it possible for the users to be able to view our pages conveniently and to find quickly what they look for.

 

What to measure in ecommerce analytics and how to improve results?

There are loads of opportunities for the optimization of an ecommerce store – you can search for best practices, case studies, but in the end it will always be your own experiences, the behaviour of your own audience on which you can base your decision whether you will benefit from a specific modification or not.

 

What will we talk about in the following?

  • What to specifically pay attention to in Analytics?
    • Audience – who is visiting, who is shopping and how?
    • Acquisition reports, or in other words, conversion cycles on your website
    • Behaviour – why do customers do what they do?
    • Conversions – where, how, and if not, why not?
  • Why not to pay attention to everything at the same time?
  • Tips so that you can improve the numbers
    • Reduce loading time
    • Provide all information
    • Grant exclusive offers based on behaviour
    • Simplify the check-out process as much as you can
    • If something does not work, get rid of it quickly
  • Is that all you have to do?

 

Most ecommerce systems offer some kind of basic features for the collection of data, but if you want to build a more significant database, you will definitely need the integration of Google Analytics. Google Analytics, by all means, can guarantee you an incredible amount of information of which you need to pick out those few indices that you will monitor continuously.

 

What to specifically pay attention to in Google Analytics used as an ecommerce analytics tool?

Reports and indices in Analytics that are essential for e-merchants can be divided into four main groups. These are the following.

 

ecommerce google analytics

 

Audience

The primary factor that any website, dealing with ecommerce, has to measure precisely is audience. Age of the customers, proportion of the returning clients and similar information can all be found here – in order to be able to build any marketing campaign effectively and to be able to target the various buyer personas, you need to know these and act in line with them.

This is where you find the demographic data. It is well known that the age of the customers and their gender can significantly influence their shopping habits, just like their reactions to a certain campaign or message, just as well how effectively they can be targeted with the given product. You may modify your supply accordingly – if you find that a different kind of audience is visiting the online store than the one you originally targeted, you can invent such promotions, or you can introduce such products that are attractive to members of that audience.

You have access to five different dimensions under Audience > Demographic data, which are Age, Gender, Attraction categories, Active market segments and Other categories.

 

Geographical data may also be important in certain cases – a professional ecommerce store can, for example, use weather-based segmentation: they can offer umbrellas at locations where there is a storm taking place, sunglasses where there is sunshine, and so on. It is not a disadvantage either if you know in which cities and regions your products are the most popular or how the different geographical segments behave.

 

Acquisition reports

Acquisition reports provide more complex information, you can learn more about the acquisition-behaviour-conversion-cycle, briefly the ABC-cycle. This means that you can find out how you acquire customers, how they behave on the website after the acquisition and what kind of conversion patterns can be associated with them.

For example if you use AdWords advertisements, you can integrate their data into Analytics and follow through the complete life cycle of the customer from the first click to the conversion.

 

Behaviour

Behaviour is also extremely important – this is from where you know for example whether the visitors, the customers will return to the website. If a lot of the visitors return, but only a few of them purchase, this may mean that your products are attractive but small impulses, for example personalized discounts may still be necessary for the conversion. If the proportion of returning customers is low, you need to examine whether you re-activate them effectively, what kind of e-mail marketing campaign you pursue, whether there is negative feedback in connection with purchase completion or delivery.

 

ecommerce analytics user behaviour
Photo credit: E-commerce via photopin (license)

 

 

Behavioural data can be found under Audience, however, it is much more than a simple subsection of the menu. You can see how behaviour is influenced by page load speed (users do not appreciate if your site is slow, they tend to leave it even only after a few seconds), by content (how much time they spend on the site, how high the bounce rate is etc.), and you can also see how the users carry out searches (what keywords they use, how much relevant data they get as a result).

 

Conversions

In order to be able to review conversion reports, you have to connect Analytics with the system of the online store – considering that you can apply lots of various payment modules or checkout techniques on the website. There are several subcategories under the conversion reports, for example customer behaviour, which shows what kinds of sites the customers visit, how they use the search engine – and this is from where you can pick out the information relative to cart abandonment, which may be especially important.

 

ecommerce analytics conversion

 

Cart abandonment is a problem that affects all ecommerce stores since a big proportion of the users who add products to the cart will not pay for it, will not order it in the end. There may be lots of reasons for that: the checkout process is too long, or you have not informed the customer in advance about the delivery price or you have given any other ambiguous information, or that they are just making a so-called list that they can find more easily later, when they are really willing to shop. If you monitor the numbers in the conversion reports, you will be able to significantly improve the conversion rate by the correction of the errors.

This is also where you can get information about how the individual products perform – which are the most popular, which are the ones that your visitors do not purchase, which ones do they usually buy together, and so on. It is easy to see why that is important – you can fine-tune the marketing or even the supply in case of the products that perform badly, or you can even offer in pack by default the products that are usually purchased together.

 

Why not to pay attention to everything at the same time?

 

The reason why you have to determine the indices that are actually the most important is because dealing with ecommerce analysis and optimization is an exhaustive and continuous task. Your audience, supply and site is constantly changing, so you can never declare it “finished”, or say that you do not have anything to do with it any more.

 

ecommerce analytics focus

 

But if you want to build every single data in the strategy, you will need a whole team to be able to do that – you will have to elaborate extremely complex plans, carry out the necessary modifications on the site according to these plans and, of course, to test everything. This consumes a great deal of time and resources, and for that reason it is best for you to identify the points most critical to you, and focus on those specifically.

It is naivety to think that this is an easy task for a large company that has its own online marketing and developer team at its disposal. If you want everything at the same time, you will simply not be able to draw the appropriate conclusions from the enormous piles of data.

This way not only planning and analysis will become work that can be realistically carried out, but the developer will also have an easier job and you might as well be able to run only a few A/B tests simultaneously and still end up with precise results concerning the outcome of the optimization.

 

tips Tips for improving the metrics numbers:

 

All websites are different – their content, their appearance, what they offer, the functions of the system may all influence how successful they are.

However, there are some basic policies, following which you can increase your conversion rate regardless of the audience and the technical solutions.

 

Reduce page load time

Customers are always impatient and this is increasingly like that in the mobile era. More and more people purchase through mobile phones, which means you have to guarantee that every single of your pages is loaded extremely quickly. If the users have to wait more than a few seconds, they will leave you and switch over to a competitor.

 

ecommerce analytics page speed

 

Provide all information

All companies are “naked” on the internet. Nowadays information can be searched easily, the users can ask for the opinion of others in a matter of seconds, they can ask questions in connection with your products or prices on other platforms. You must do your best to provide them with all necessary information so they will not have any questions at all – you have to give them an intuitive frontend, where they can easily find their way around, and to indicate such information like, for example, shipping costs on the product pages. Never let them be unpleasantly surprised because you lose customers if you do so, and thanks to public feedback, maybe even more than one at a time.

 

Grant exclusive offers based on behaviour

  • When you see that one wants to leave your site without having purchased anything, throw a pop-up message in front of him in which you grant a discount valid only there and then.
  • If a user regularly buys the same products in your store, send him or her an e-mail and offer regular, automatic delivery of those products without a need to further orders.
  • If one packs one’s cart full, but does not purchase, send him or her an e-mail that he or she can buy the given products with some discount.

 

There are infinite possibilities available and thanks to the data, you can follow precisely the behaviour of your every single visitor. All you have to do is to build such a database, to create such a system, in which you automatically target the ones showing given behavioural patterns with certain offers.

Once you know well how people use the search engine or what kind of products they like looking at, offer them products that comply with their preferences on every single page. And if you find that they are just looking around, redirect them to some of your contents which may convince them that it is worth shopping in your store at that moment.

 

Simplify the checkout process as much as possible

By all means use a method that requires the least possible effort from the potential buyers for making a payment. Do not lead them through five different pages, do not request their registration and do not ask even for their blood type. While providing all necessary information, within one or two pages ask for their data indispensable for payment and delivery, and then it is done.

 

ecommerce analytics checkout process

 

This will increase the conversion rate and ameliorate the user experience. A high proportion of cart abandoners do not convert in the end because the ecommerce store requires too much from them.

You should definitely ask for their e-mail address and marketing goes smoothly from there: you can find them later with individual offers and content tailored to them – but you should really leave this for later and should not want to shove everything down their throats immediately.

 

If something does not work, get rid of it quickly

There will be some coupons, promotions, offers and even some products that the users will simply not like – furthermore, there may even be some that are not worthwhile for you to keep for some reason.

Do not insist on keeping these, you should rather invent new ones constantly. You can invent unlimited quantities of creative customer acquiring methods based on customer behaviour, or you can find newer and newer solutions to increase the average value of purchases. However, this will work only if you have ears for the messages that the data send you.

 

SUMMARY

This may seem more simple in writing, which is why it is important to emphasize that this is a permanent job: optimization based on ecommerce analytics must be uninterrupted, otherwise you will realize after a well done modification or campaign that your conversion rate is again in decline.

You have to be able to modify your online store quickly so that you can react upon unexpected situations as well (e.g. the appearance of a previously not reached major audience that has been directed to the site by an exceptionally successful viral content). You also have to train all of your systems simultaneously – your content, the ecommerce store itself, your AdWords advertisements, e-mail campaigns will all have to be harmonized in order to reach the most people and to actually make them convert – preferably several times.

 

ecommerce analytics coninuous work

Never stop. You should always keep an eye on ecommerce analytics…