Magento Modules
Modules are the core of Magento. Every action on the site, frontend or backend,
goes through a module. Modules act as containers for one or more of the following:
settings, database schemas, rendering objects, utility helpers, data models, or
action controllers. A module can be made of all six of these things, or just one.
Modules are defined as being on or off in an XML configuration system located in
app/etc/modules/. Each module can specify its own settings in an XML file as well,
located under themodule’s etc/ directory.
Since everything in Magento is a module, and modules have self-contained configuration
and database settings, this allows you, as a developer, to extend Magento
exactly as the core system is built.
Module Structure
Belowyou can see the directory structure of the Catalog module. The catalog module
contains all of the aspects of a module.
- Mage/
|- Catalog/
| |- Block/
| |- Helper/
| |- Model/
| |- controllers/

| |- etc/
| – sql/
Code Pools
Modules are located in one of three code pools. The code pools are: core, local, and
community. All of the modules distributed with the base Magento are in the core
code pool. All of the custom modules that you develop can be installed in the local
code pool. The community pool was originally designed for installed third-party
modules, but this idea might be phased out, as you can simply install any module in
local as well as community.
- app/
- code/
|- local/
|- community/
- core/
Module Packages
All models exist under a package directory. The package serves no purpose other
than to allow for consistent naming of classes. All Magento modules are part of the
Mage package. Thus, all Magento class names begin with Mage_. It is an acceptable
practice to create a new package for your custom modules that has the name of your
company or organization instead of Mage. There is no functional detriment when not
using Mage as your package.
Models
Models are the muscle ofMagento. They help move data from the database into the
program itself. The output, or rendering, of the data is done by the Blocks, but the
models are mainly responsible for manipulating the data. Models, in any programming
environment, help to identify and shape data domains. What this means is that
models draw boundaries between definitions of data groups and relate data groups
to other data groups.

Heavy Custome Developed Zen Cart Template For Sale

heavy-custome-developed-zen-cart-template-for-saleThis template is developed for lightinthebox . Demo site: www.aiaok.com

The most powerfull Shopping mall you could find out!!Don’t miss the chance  to improve your business.

The price is  300USD   contact:  processorder@gmail.com

This is a small face Magento free theme

Installation instruction
1. Unzip the archive
2. Copy all files under /root in your shopdirectory
3. Navigate to the Magento admin panel, then the Design configuration tab (System -> Configuration -> Design) and assign refresh to your store.   Share by magento
4. Adjust some information pages under CMS-> Manage Pages and Static blocks.

refresh_magento_k

Demo site: http://www.5dnet.de/

Download

Exploring Magento
Magento’s administrative interface gives you control over all the standard features of
your shopping cart site. Looking at this backend interface can shed some light on
what features Magento has to offer. Login to the backend with the admin account
which you setup during the installation and you will see something.

Figure 3.1
Magento provides standard functionality that you would expect from any shopping
cart, including:
• Multiple category trees

• Definable attributes
• Customer and customer groupmanagement
• Discount rules for promotions
• Newsletter management
• Web page manager
• Order review system
• Reporting features
• System configuration and settings
In addition to these features, there are a number of features that would not be provided
by default in other shopping carts. A short list of these impressive features
include:
• Reviewing search terms
• Reviewing customer tags
• Poll manager
• Currency exchange rates
• Google Sitemap integration
• Abandoned shopping cart report
• Layered category navigation
None of these features by themselves are probably that impressive. But to have a
system in which they are all present, by default, with no plugins necessary, is truly a
breath of fresh air in the open source e-commerce arena.
By now, you’ve probably “clicked” around in the backend a little. The remainder
of this chapter will guide you through the basics of what Magento has to offer and
cover Magento specific terms. It is necessary to have a thorough understanding of
Magento’s basic operation in order to better understand the code. Let’s start with
Magento’s product catalog.

Developing for Magento
Prep Your Environment
Make sure you have themost up-to-date version ofMagento downloaded.
Start by downloading the latest release of Magento from

http://magentocommerce.com/.

LAMP/WAMP Platform
If you are on theWindows platformthe easiest way to install PHP, Apache andMySQL
is with the XAMPP family of packages from http://apachefriends.org. Install the
XAMPP-lite package anywhere on your drive and run the setup.bat file. There is a
version of XAMPP forMac OS X and Linux as well.
Subversion
For developing your own modules, it is recommended that you use Subversion
version control to keep track of all of your code changes. TortoiseSVN from
http://tortoisesvn.tigris.org is the recommended client and server for Windows
users. For Mac and Linux users, the command line svn program plus the PHP package
websvn is recommended. If you are not familiar with the Subversion system, you
can read more about it at the SubversionWeb site (http://subversion.tigris.org/).

MySQL Tools
Apart from the actual MySQL server, it is most useful to have a graphical client to
inspectMagento’s database tables from time to time. TheMySQL Query Browser tool
is the official client provided by MySQL AB and is available for all major operating
systems. Some users prefer mysqlcc or phpMyAdmin over MySQL Query Browser,
though.
Installation
Unzip Magento into your Web server’s document root (from here on, referenced as
{docroot}). You should see a directory layout like this:
{docroot}/magento/
app/
index.php
js/
lib/
LICENSE.txt
media/
pear
skin/
var/
Database Setup
Magento will not create its required database for you, even if your database user
has proper rights to create a database. Because of this, we will need to create the
database using one of the previously mentioned MySQL tools. A normal database
name, sometimes called a schema, can be “magento”, or “magento_dev”, or you can
even include the version number “magento_10”.
Magento Setup
You should now continue withMagento’s base installation by pointing your browser
to http://localhost/magento/. Here, you will see a basic step-by-step form for in

stalling most PHP Web applications. Follow the on-screen directions and your Magento
installation will be complete.
Sample Data
If this is your first time trying out Magento you should install the optional sample
data. The sample data is provided as a separate download as it is about 35 MB. The
sample data provides some sample products, categories, and product images. Once
you have downloaded the package, copy the media folder over your own media folder
under your Magento installation. Then run the provided SQL file with your MySQL
management tool.
As of the time of thiswriting, the sample data is distributed as a complete database
installation. Therefore, it needs to be inserted before you proceed with the regular
setup. The regular setup will actually upgrade the sample data to the latest version.
Initializing Subversion
Magento has three directories from which modules are executed: core, community,
and local. All the examples in this book assume that you are developing in the local
module directory. Under the local directory, you can group all of your modules together
under one package. This package is called Mage for all magento core modules,
but this book will use Company for all the examples. You can use any package name
besides Company for a package name that represents your company or organization.
Initializing subversion is a bit tricky. First, you need to initialize a repository. Then,
you need to create a folder or directory to import into this new repository. After that
you are not ready to start using subversion. The directory which was imported needs
to be removed, and then checked out of the repository in order for it to be connected
with subversion. Let’s look at the steps in detail.
Picking a subversion repository on the Linux platform is pretty easy. After
installing Subversion from RPM, there usually exists a directory similar to
/var/lib/subversion/repositories/. Initialize a new repository with the command:
svnadmin create /var/lib/subversion/repositories/magento_modules

If you are using TortoiseSVN underWindows, create a folder anywhere on your computer,
right-click that folder, and select Create repository here… from the TortoiseSVNmenu.
Our goal for setting up Subversion is to have a folder named Company under the
app/code/local directory of Magento. This will allow us to easily add new modules
and save our work to Subversion whenever we want. Create a new directory under
the app/code/local folder called svn_import. Under this temporary svn_import directory
create another folder called Company, or whichever name you’ve decided to use
for your packaging. If you are running on a Unix platform, run this command from
inside the svn_import directory (ignoring the shell prompt):
[svn_import]$ svn import . \
file:///var/lib/svn/repositories/magento_modules/
OnWindows, use TortoiseSVN by right-clicking on the svn_import folder and choosing
the Import… menu item. A new dialog will appear and ask you to input the
URL of the repository. Click the ellipses button and browse to the folder which you
designated as your repository in the previous step.
Delete the svn_import folder after successfully importing into your new repository.
Next, we need to checkout the folder we just imported to get a Subversion activated
directory. On Unix:
[local]$ svn checkout \
file:///var/lib/svn/repositories/magento_modules/Company
OnWindows, right click on the local folder and choose SVN Checkout…. Accept the
default settings in the dialog, and confirm Yes when it asks you if you really want to
overwrite the folder.
Covering all Subversion commands is beyond the scope of this book. But you are
now prepared to develop and save your custom Magento modules in a subversion
directory if you so choose.

Sun
24
May
12:12 pm

Who Can Use This Use Guide?
Developers
This book should serve as a thorough introduction for developers to the structure
of Magento, as well as provide you with enough examples that you can take any of
your coding ideas to fruition. Developers will learn how to write custom modules
for Magento for redistribution or for simply deploying on a corporate installation of
Magento.
Store Owners
If you are not a programmer, but simply want to run a Magento store, this book
might not be for you, but if you think you might need custom programming for your
shopping cart this book can help you communicate better with your developers.
It’s tough to avoid getting the wool pulled over your eyes when hiring a remote
developer. Armed with the knowledge ofMagento provided by this book, you should
be able to verify any cost estimates you receive and find out if your developers are
stalling or not.
About This Book
This book is organized roughly into two sections. The first section describes how
Magento works from a code perspective and from a general user-interface perspective.
The remaining chapters will walk the reader through building various modules
forMagento by example. Although not a complete detail ofMagento’s API, this book
should give the reader all the learning by examples that he or she should need to
understand all the concepts that driveMagento’s code.
Code Formatting
SinceMagento is built on the Zend Framework the code formatting of the examples
in this book will follow the Zend Framework style guidelines. Sometimes the code

examples in this book are shortened to fit on the pages, so style may suffer in some
instances to conserve space.
When referring to variables, classes, objects, or concepts this book will put the
word or words in question into italics. When specifically referring to the word of a
variable, class name, etc. the words will be formatted as inline code. File names will
also be formatted this way.
When talking about Mage_Core_Model_Abstract the object class italics will be
used, but when talking about why a class is named Mage_Core_Model_Abstract, inline
code formatting will be used.
XML Examples
When referencing XML the ellipses, …, are used to suggest that other, optional, or
pre-existing XML tags are present. Given the XML structure below:
<config>
<modules>
<Company_RewardPoints>
<version>0.1.0</version>
<depends>
<Mage_Customer />
<Mage_Checkout />
</depends>
</Company_RewardPoints>
</modules>
<global>
<resources>
<rewardpoints_setup>
<setup>
<module>Company_RewardPoints</module>
<class>Mage_Core_Model_Resource_Setup</class>
</setup>
<connection><use>core_setup</use></connection>
</resources>
</global>
</config>
The section enclosed in the rewardpoints_setup tag may be represented as this:
<config>


<global>

<resources>
<rewardpoints_setup>
<setup>
<module>Company_RewardPoints</module>
<class>Mage_Core_Model_Resource_Setup</class>
</setup>
<connection><use>core_setup</use></connection>
</resources>

</global>

</config>
Operating SystemConsiderations
When possible, this book will describe technical procedures for Linux,Mac OS X, and
Windows operating systems. However, to keep examples brief, simple references to
file locations will use Windows directory and file naming conventions. When listing
directories, the forward slash (/) will be used as a directory separator as this convention
falls in line with standard Unix behavior (Mac OS X and Linux) plus PHP and
Apache can automatically translate forward slashes to back slashes where need be
onWindows.
Do not be surprised to see a directory like this:
C:/xampp/apache/htdocs/magento/

When you use Magento connector upgrade or install any extensions there usually meet Magento Connect Files Permission Problem.Many hosting like VPS don’t support this confunction.

You need use the SSH  Type the following commands:
find . -type d -exec chmod 777 {} \;
find . -type f -exec chmod 644 {} \;
That’s it.  Now you’ll need to navigate to your web root folder from your browser and get the rest setup.

Magento Storefront Show Instock Products Only

Define product mould:$_productC = Mage::getResourceModel(’reports/product_collection’);

John code: $_productC->joinField(’inventory_in_stock’, ‘cataloginventory/stock_item’,’is_in_stock’, ‘product_id=entity_id’, ‘{{table}}.is_in_stock=1?);

Example:

$storeId    = Mage::app()->getStore()->getId();
$category = Mage::registry(’current_category’);
$_productC = Mage::getResourceModel(’reports/product_collection’)
->addViewsCount()
->addAttributeToSelect(’*’)
->setStoreId($storeId)
->addStoreFilter($storeId)
->addCategoryFilter($category)
->setPageSize(12)
->setCurPage(1);

Mage::getSingleton(’catalog/product_status’)->addVisibleFilterToCollection($_productC);
Mage::getSingleton(’catalog/product_visibility’)->addVisibleInCatalogFilterToCollection($_productC);
$_productC->joinField(’inventory_in_stock’, ‘cataloginventory/stock_item’,’is_in_stock’, ‘product_id=entity_id’, ‘{{table}}.is_in_stock=1?);
$this->setProductCollection($_productC);

Magento Stores Ecommerce Search Engine Optimization
1.1. General Configuration

Magento is one of the most search engine friendly e-commerce platforms straight out of the box, but there are several known issues that can be taken care of to optimize your Magento SEO. The first step is to get the most recent release, 1.2.1. Then, to get started, enable Server URL rewrites. You will find this setting under System => Configuration => Web => Search Engines Optimization. Another good thing to configure now you are on this screen is “Add store Code to Urls” under “Url Options”. In most cases it is better to set this functionality to “No”.
1.1.1. WWW and  non-WWW

Under “Unsecure” and “Secure” you can find the Base URL, where you can set the preferred domain. You can choose between the www and the non-www version of the URL. With changing the setting you don’t create a redirect from www to non-www or non-www to www but set only the preferred one. Therefore it is a good idea to create a 301 redirect through .htaccess with mod_rewrite. When editing the .htaccess file you can add the following code to redirect index.php to root.

Around line 119:

RewriteBase / RewriteCond %{THE_REQUEST} ^[A-Z]{3,9}\ /index\.php\ HTTP/
RewriteRule ^index\.php$ http://www.mydomain.com/ [R=301,L]

Or, when your Magento install is not in the root but in the sub-directory http://www.mydomain.com/magento/:

RewriteBase /magento/ RewriteCond %{THE_REQUEST} ^[A-Z]{3,9}\ /magento/index\.php\ HTTP/
RewriteRule ^index\.php$ http://www.mydomain.com/magento/ [R=301,L]

1.2. Header Settings

By default your Magento install has the title “Magento Commerce”. For your Magento shop to get the traffic it deserves you should keep at your mind:

* Search engines put more weight on the early words, so if your keywords are near the start of the page title you are more likely to rank well.
* People scanning result pages see the early words first. If your keywords are at the start of your listing your page is more likely to get clicked on.

First of all you should get rid off the default title “Magento Commerce”. Go to Configuration => Design => HTML Head. Choose a good and descriptive title for your website. This title will be used for several non-content pages without custom title, e.g. “Contact Us” and the “Popular Search Terms”.

To add your store name to all page titles, including categories and products, put your store name in “Title Suffix”. It is a better idea to keep the Prefix empty, for the reasons mentioned above. Also keep “Default Description” and “Default Keywords” empty. For a non-production environment, to prevent indexing of the site, it may be useful to set “Default Robots” to “NOINDEX, NOFOLLOW” but for all other applications make sure it is set to “INDEX, FOLLOW”.

Now we are optimizing the <head> of your web-store pages it is a good idea to add the new canonical tag. You can install the Canonical URL’s for Magento Module to add them to your head and improve your Magento SEO.

For some reason Magento turns non-set meta robots into a meta tag in this style:

<meta name=”robots” content=”*” />

This can result in some very strange behavior in the search engines, so we’ll remove it. To remove this empty metas from your code install the Yoast MetaRobots Module.
1.3. CMS Pages

At first sight Magento may lack some descent CMS functionality, but for most uses it will be flexible and powerful enough. One of the benefits of this simple CMS is that you can control each aspect of the pages. Once you’ve given each CMS page some decent content, pick a SEF URL Identifier and page title, (while keeping in mind the points under 1.2), and go to the Meta Data tab to write a description for each CMS page that you actually want to rank with.

You can keep the “Keywords” empty. The description has one very important function: enticing people to click, so make sure it states what’s in the page they’re clicking towards, and that it gets their attention. Thus, the only well written description is a hand written one, and if you’re thinking of auto generating the meta description, you might as well not do anything and let the search engine control the snippet…

If you don’t use the meta description, the search engine will find the keyword searched for in your document, and automatically pick a string around that, which gives you a bolded word or two in the results page.
1.4. Category optimization

Magento gives you the ability to add the name of categories to path for product URL’s. Because Magento doesn’t support this functionality very well – it creates duplicate content issues – it is a very good idea to disable this. To do this, go to System => Configuration => Catalog => Search Engine Optimization and set “Use categories path for product URL’s to “no”.

Now it’s time to set the details for each category. Go to Catalog => Manage Categories. The most important fields are:

* Meta Description: put an attractive description here; Keep in mind that people will see the description in the result listings of search engines.
* Page Title: keep this empty to use the category name including parents categories. When you customize it, the title will be exactly like your input, without the parent category.
* URL Key: try to keep a short but keyword rich URL. Removing stop words like “the”, “and”, “for” etc. is usually a good idea. Also note that you can set this only for all store views, for a multi-language store you should keep it language independent.

For each store view you can specify the Name, Description, Page Title and Meta data. For multi-language stores this is really a great feature.
1.5. Products optimization

Optimization of the Products pages is similar to Categories. You can set the Meta Information for the “Default Values” and for each “Store View”. Note that for the “Meta Title”, this will overwrite the complete page title, including categories but except title prefix/suffix, and not just the product name.

An often-overlooked aspect of Magento SEO is how you handle your images. By for instance writing good alt tags for images and thinking of how you name the image files, you can get a nice bit of extra traffic from the different image search engines. Next to that, you’re helping out your lesser able readers who check out your site in a screen reader, to make sense of what’s otherwise hidden to them.

By default the images will be renamed to the product title, the same for titles and alt tags. With some extra effort you can set the titles and alt tags for each product image. Under the tab “Images” of the Product Information you can set the label for each product image, this value will be used for the alt and title tag. Of course you can do this for each specified Store View as well.
2. Magento Template Optimization
2.1. Optimized Blank Template

The default Magento skins like “Default Theme”, “Blue Skin” and “Modern Theme” don’t do a very good job in the use of headings, so from an SEO perspective, there is a lot of room for improvement there. To make it easy on you, we have developed a Blank Magento SEO Theme, based on the core Magento Blank Theme, which incorporates all the things we’ve outlined below. You can download and discuss it here.
2.2. Headings

By default the logo is an <h1>, which is should only be on the front page, and on all other pages it should be no more than an <h3>. The most important thing is to get the title of the content in an <h1> tag, e.g. for a category page should it be the category name and for a product the product name.

The next step is to clean up the over usage of headings. It’s a good idea to get rid off the header usage in the side columns, or make the text relevant to the shop (ie. include keywords). There is no reason to add “static” and keyword less titles with an <h4>. It is, for instance, better to change all the <h4> tags in <div class=”head”> to <strong> tags. Now it is time to optimize your content, at the category pages put the product names in a <h3> and the category name in a <h1>. On product pages, you should put the product name in an <h1>.

To learn more about why proper headings are important read this article on Semantic HTML and SEO.
2.3. Clean up your code

All that javascript and CSS you might have in your template files, move that to external javascripts and css files, and keep your templates clean, as they’re not doing your Magento SEO any good. This makes sure your users can cache those files on first load, and search engines don’t have to download them most of the time.
2.4. Magento Store Load speed

A very important factor in how many pages a search engine will spider on your shop each day, is how speedy your shop loads.

You can do two things to increase the speed of your Magento install:

1. Enable caching. Go to System => Cache Management and enable all caching features, like this.
2. The importance of a good host and server config. With MySQL and PHP opcode cache you can improve the speed of Magento dramatically.

NOTE: there is a rumor that with the 1.3 release of Magento new functionality will be added with huge performance improvements.

Another thing to look for is the number of external files. For each file you make people download, their browser has to create another connection to the webserver. So it is a very good idea to reduce the number of external files and combine several external files in to one. By default Magento already combines (almost) all javascript files into one file.

It doesn’t do this for stylesheets though: the default template has 6 different stylesheet files. You can combine the content of these stylesheets into one new one, except for the print.css file, or you can use the Fooman Speedster module. Besides combining files, this module also compresses and caches your javascript and stylesheet files. (Please note the requirements for Speedster: mod_rewrite has to be enabled & and your server needs to have .htaccess support. If you use Canonical URLs for Magento and Fooman Speedster together, you need to overwrite the Canonical module with this download.
3. Magento SEO – Duplicate Content Problems.

Once you have done all the basic stuff you will find the rest of the problems amount to one simple thing: duplicate content. Loads of it in fact. For products you have, at least, the following URLs with exact the same content:

* domain.com/product.html
* domain.com/category1/product.html
* domain.com/catalog/product/view/id/1/
* domain.com/catalog/product/view/id/1/category/1/

Besides that you have pages like the product review pages with almost the same content. Another problem are categories, you get a load of duplicate content with layered navigation and the sorting options. In essence that means that, worst case scenario, a product is available on 4 pages at least next to the page where it should be available.

We’re going to get rid of all those duplicate content pools, by still allowing them to be spidered but not indexed and fixing the sorting options and layered navigation for categories.
3.1. Noindex, follow for non-content pages

Install the Yoast robots meta module and make sure the settings prevent indexing of all non-content pages,

Now the search engine will follow all links on these pages but it won’t show those pages in the index.
3.2. Nofollowing unnecessary links

Another easy step to increase your Magento SEO is to stop linking to your login, checkout, wishlist, and all other non-content pages. The same goes for your RSS feeds, layered navigation, add to wishlist, add to compare etc. Still there is no plugin for Magento to work this around. You had probably have to go into your template files to add nofollow to those links by hand.
3.3. Canonical URLs

To help search engines to understand the duplicate content of your pages you can suggest the preferred version of the URL for each page, using the new canonical URL tag, so you should install the Canonical URL’s for Magento module.
3.4. XML Sitemaps

XML Sitemaps are an easy way of letting search engines know where your content is, it won’t help you rank, but it might help you get indexed faster. You can create an XML sitemap manually by going to Catalog => Google Sitemap => Add Sitemap, choosing a filename, path and store view, and then pressing “Save & Generate”.

You can then simply put the following code in your robots.txt file to point the search engines to your sitemap.xml file:

Sitemap: /sitemap.xml

As your inventory changes, you’ll have to re-generate XML sitemaps. To make sure they’re up to date, the best way is to set up a cron job, the process of which is extensively describe here.
Conclusion: Magento Search Engine Optimization development

This article has covered all the aspects of Magento SEO, if you have any feedback, or additions, Contact Us. We’re working closely with the Magento core development team to improve the SEO aspects of Magento.

Wordpress Ecommerce Online Shopping Theme download available.

Why Choice Wordpress with Ecommerce Themes For Your online store?

  • Simple html knowlage need, Easily customizable
  • Easy Search engine optimized, wordpress have very good SEO structure which power your ecommerce online store good ranking on google,yahoo..
  • Easy Manage your store online, Magento store need more professional knowlage on it and its many steps to add products to your store.This simple wordpress store good for stores have few products.
  • Use your own domain name to sart your own small business.

Save time,  money and hassle of building a custom ecommerce online store! If you have intresting on that please feel free contact us or leave a comment.

wordpress ecommerce  online store

wordpress ecommerce online store