Search This Blog

Tuesday, May 22, 2012

Magento Enterprise Edition 1.12 New Features



Magento Enterprise Edition 1.12 New Features

1) Mobile HTML5
Quickly and easily create a storefront optimized for mobile devices so customers can shop even when they’re on the go. This mobile interface uses HTML5 technology and supports iPhone, Android and Mobile Opera browsers. It includes out-of-the-box features such as:
·      Device-specific media capabilities for audio and video
·      User-friendly search and results display
·      Clean display of product detail pages
·      Pinch, multi-touch and scaling images
·      Easy swipe between product images
·      Zoom capabilities
·      Cross-sell and up-sell capabilities
·      Drag-and-drop of products to the shopping cart

2) Visitor Segmentation
Tap into a whole new customer segment – unknown site visitors. Whether they’re new visitors or returning customers who have not logged in, you’ll now be able to identify and target them with special promotions to convert browsers into buyers.  

3) Expanded Rule-based Product Relations

Our rule-based product-relations functionality allows merchants to target specific customer segments with product recommendations. Pinpoint specific customers with up-sells, cross-sells and related products to create a more relevant shopping experience.

4) Auto-generation of Coupon Codes

Generate a set of unique coupon codes for each promotion you run and export the list of codes for offline distribution, email, newsletters and more. Easily manage and monitor coupon usage and generate detailed reports.

5) Multiple Wish Lists

Customers can save products to multiple wish lists and copy or move items from list to list. They can make their wish lists public so they’re searchable by anyone. And merchants can review them to learn about their customers’ wants and needs.  

6) Layered Navigation Pricing Enhancement

We’ve introduced a new set of algorithms for price-layered navigation that provides much greater flexibility. Now you can display a range of prices that is based on having a similar number of products within each range, giving you better control of your customers’ search results, and helping your customers find what they’re looking for faster.

7) Customer Group Pricing

One price doesn’t always fit all. This tool allows you to create different price points for different customer groups, such as wholesalers and retailers. You can determine both base price and tiered price levels.

8) Add to Cart by SKU

Streamline the ordering process, especially for B2B customers, by enabling them to enter a list of SKUs without having to go into product pages. This simplifies large orders, recurring orders and ordering based on offline catalogs.

9) REST APIs Support

The new Magento REST API uses three-legged OAuth 1.0a protocol to allow applications to safely access Magento services. What this means for you? You can manage customers, customer addresses, sales orders, inventories and products using HTTP verbs (GET, POST, PUT, DELETE). Data requests and responses can be in XML or JSON format.
This initial version of the REST API supports the following functions:
·      Create/Retrieve/Update/Delete a simple product
·      Retrieve a list of orders and specific order information
·      Update/Retrieve catalog inventory
·      Create/Retrieve/Update/Delete complete customer information

                        10 )European Union VAT-ID Validation

This feature facilitates the tax collection process for online businesses in the EU and greatly simplifies international B2B transactions by automatically applying the correct tax rules. Taxes can be calculated and charged according to VAT customer groups, based on customer shipping or billing addresses and VAT IDs.  

11) EU Cookie Restriction

Our response to the recent EU Privacy and Electronic Communications Directive? A new cookie notification feature that simplifies the compliance process. Once enabled, a message at the top of the storefront informs site visitors about the cookie policy and prompts them to accept or decline.

12) CMS Page Hierarchy Enhancements

Managing your CMS hierarchy tree just got easier. Now you can add CMS pages to the navigation menu without custom development. You can also create, copy or delete different CMS hierarchy trees for each website and store view individually or en masse..

13) Backup and Rollback

Manage and schedule a variety of backup operations with the option to rollback the changes to reverse any modifications. This feature is particularly useful when testing new modules or customizations, or when upgrading to a new version of Magento. You can review specific customizations and their impact on the new code. (We do not recommend using this feature in your production environment.)
Three types of backup are supported:
·      System Backup
·      Database Backup
·      Database and Media Backup

                        14) Payment Bridge 1.1 Updates

Magento Secure Payment Bridge, our PA-DSS certified payment application, adds multiple new payment methods. In addition to our existing supported gateways – PayPal, Authorize.net and Payflow Pro – we are introducing support for the following new gateways:
·      Psi Gate
·      RBS Worldpay
·      Database and Media Backup
·      Braintree
·      First Data
·      Card Gate Plus
·      DIBS
·      eWay Direct
·      Ogone Directlink
·      Paybox
·      Payone
·      Sage Pay
·      CCAvenue
Supported by services provided by Braintree or Authorize.net, customers can also securely save their credit card information for future transactions in a “My Credit Cards” section in “My Account.” And with support from Kount, you can integrate fraud-screening services with your payment methods (requires separate agreement with Kount).

                        15) CAPTCHA

Now you can enable CAPTCHA functionality on your site to help prevent automated software from attempting fake logins. This auto-generated test ensures that the login is being attempted by a person and can be enabled in both the admin and customer login areas.

Sunday, May 20, 2012

SVN Installation

Install svn on helios

Step 1 download helios

http://www.eclipse.org/downloads/packages/eclipse-php-developers/heliossr2

Step 2
To install subclipse install http://subclipse.tigris.org/update_1.8.x from install new software link else
refer to the link for complete details

http://subclipse.tigris.org/servlets/ProjectProcess;jsessionid=C264D78FF3EA3F93B5F42C2E10616D6D?pageID=p4wYuA

EAV Part II


Most Important Tables in magento are: eav_attribute and eav_entity_type

PRODUCT
                Main Table: catalog_product_entity
                                catalog_product_entity_datetime
 catalog_product_entity_decimal
 catalog_product_entity_gallery
                catalog_product_entity_int
 catalog_product_entity_media_gallery
 catalog_product_entity_media_gallery_value
catalog_product_entity_text
                catalog_product_entity_tier_price
 catalog_product_entity_varchar

CATEGORY
                Main Table: catalog_category_entity
                                catalog_category_entity_datetime
 catalog_category_entity_decimal
 catalog_category_entity_int
 catalog_category_entity_text
 catalog_category_entity_varchar
catalog_category_product


PARTY
                Main Table: customer_entity   and customer_address_entity
                                customer_entity_datetime
 customer_entity_decimal
 customer_entity_int
 customer_entity_text
 customer_entity_varchar
 customer_group
 customer_address_entity_datetime
 customer_address_entity_decimal
 customer_address_entity_int
 customer_address_entity_text
 customer_address_entity_varchar

ORDER
Main Table: sales_flat_order
 sales_flat_order_address
 sales_flat_order_grid
 sales_flat_order_item
 sales_flat_order_payment
 sales_flat_order_status_history

Magneto database structure for dummies How does EAV work?

as Magento has almost 40 tables for the products and category’s alone! To understand why, let us use the product table as an example.

Rather than store all product information in one table, Magento splits this information up into sub tables. The top table in this hierarchy is catalog_product_entity. If you take a look at this table in phpMyAdmin, you will see that it includes simple base information for a product and does not appear to include any useful information other than the SKU! Fortunately, using this table it is possible to build a full product record from the attribute and value tables.
To start building a full product record, you will need to start joining attributes to the product entity table. Before you do this, take a look at the table called eav_attribute. eav_attribute is the main attribute store for Magento and is used to store attributes for all different entities (product, customer, order, category etc).

Open this table in phpMyAdmin and click browse. Notice that there are hundreds of different attributes, some even with the same name? At first this confused me because I wasn’t sure how Magento could differentiate between the two different attributes called name. How did Magento know which one was for the product and which one was for a category? As is usually the case with Magento, a small bit of research led me to the extremely simple answer: entity_type_id! Each entity (product, category, customer etc) is given an entity_type_id. To find this out, go back to catalog_product_entity and look for the entity_type_id field. The value for every record in that table should be 4, as this has been designated as the entity_type_id for products. If you were to look in catalog_category_entity you should see a different entity_type_id. Using this value and the attribute code, it is possible to load the attributes for a product, or any entity.

Now that you can get attributes and entities, it is time to start getting values. Values are separated across several different tables for reasons that I will go into shortly. For now though, just take a look at all tables that begin with catalog_product_entity. The way the values are split depends upon their type. For example, all prices and other decimal attributes are stored in catalog_product_entity_decimal where as all short text strings are stored in catalog_product_varchar. To figure out which table each attribute is stored in, Magento uses the column backend_type in the table eav_attribute. If you run the following query you should be able to find out the backend type for the product attribute ‘name’


Hopefully the above query returned the backend_type varchar, which is the correct type for name and all other short text strings. Based on what was said above, we can determine that the value for the name attribute will be stored in catalog_product_entity_varchar

Magento EAV Entity, Attribute Value in simple language for dummies....


What is EAV?

EAV stands for Entity, Attribute and Value. Let’s look at each part of that and try to understand them a little better.

Entity

The entity represents Magento data items such as products, categories, customers and orders. Each entity (product, category etc) will have its own entity record in the database.
e.g human being is an entity

Attribute

The attributes represent data items that belong to an entity. For example, the product entity has attributes such as name, price, status and many more.
e.g attributes of human being are like eyes, ears, nose, hair color etc…

Value

The value is the simplest to understand as it is simply a value linked to an attribute.
To better understand this, let us consider the product entity. Each product entity will have a series of attributes, one being the attribute name. Each product will then have a value for the attribute name (and all other attributes). This might not be clear yet but keep reading!
e.g value of attribute eyes of entity human being is black etc….

ANATOMY OF A MAGENTO LAYOUT FILE, layout, structure, xml

ANATOMY OF A MAGENTO LAYOUT FILE

<Handle>
Handle is an identifier by which the application determines what to do with the updates nested by it.

If the name of the handle is <default>, then the application knows that its nested updates must be loaded on almost all the pages of the store prior to loading page-specific layout (”almost all” because some exceptional pages like the product image popup do not load the layout in the <default> handle).

If Magento finds handles other than <default>, it will assign the updates nested inside the handle to the according page specified by the handle.

For instance, <catalog_product_view> contains the layout updates for the Product View page, while <catalog_product_compare_index> contains those for the Compare Product page.

Handles are set-in-stone identifiers that a designer, with no extensive understanding of Magento programming, should never need to modify.

-----------------------------------------------------------

<BLOCK>
Magento determines the behavior and visual representation of each building block of a page via the <block> tag. We have already mentioned the two types of blocks Magento employs
 - structural blocks and content blocks.

A structural block usually contains the attribute ”as,” through which the application is able to communicate with the designated area (using the getChildHtml method) in a template


You will notice many occurrences of this ”as” attribute in the default layout, because by nature the default layout is one that builds the groundwork upon which the page-specific layouts can begin adding onto. For instance, in the default layout, there are structural blocks such as ”left,” ”right,” ”content” and ”footer” being introduced.

basisThe available attributes for <block> are:

• type – This is the identifier of the module class that defines the functionality of the block. This attribute must not be modified.

• name – This is the name by which other blocks can make reference to the block in which this attribute is assigned (see diagram 3).

• before (and) after – These are two ways to position a content block within a structural block. before=“-” and after=“-” are commands used to position the block accordingly at the very top or very bottom of a structural block.

• template - This attribute determines the template that will represent the functionality of the block in which this attribute is assigned. For instance, if this attributes is assigned ‘catalog/category/view.phtml’, the application will load the ‘app/design/frontend/template/catalog/category/view.phtml template file.

• action – <action> is used to control store-front functionalities such as loading or unloading of a JavaScript. A full list of action methods will soon become available, but in the mean time the best way to learn about the different action methods is by playing around with them in the currently available layout updates.

• as – This is the name by which a template calls the block in which this attribute is assigned. When you see the getChildHtml(‘block_name’) PHP method called from a template, it is referring to the block whose attribute ”as” is assigned the name ‘block_name’. (i.e. The method <?=$this->getChildHtml(‘header’)?> in the a skeleton template correlates to <block as=“header”> ).

------------------------------------------------------------------------
<REFERENCE>
<reference> is used to make reference to another block. By making a reference to another block, the updates inside <reference> will apply to the <block> to which it correla
To make the reference, you must target the reference to a block by using the ”name” attribute. This attribute targets the <block> tag’s ”name” attribute. Therefore, if you were to make a reference by <reference name=“right”>, you are targeting the block named <block name=“right“>

To make the reference, you must target the reference to a block by using the ”name” attribute. This attribute targets the <block> tag’s ”name” attribute. Therefore, if you were to make a reference by <reference name=“right”>, you are targeting the block named <block name=“right“>.

-----------------------------------------------------------------------

RULES OF XML
The only set rule you need to remember with regard to XML is that when a tag opens, it must either be followed by a closing tag(<xml_tag></xml_tag>) or self-close(<xml_tag/>) exactly as required by xHTML file tags.

-----------------------------------------------------------------------

HOW TO FIND WHICH LAYOUT FILE TO MODIFY

To access the layout files, go to app/design/frontend/design_package/theme_variation/layout/. Just like the templates, layouts are saved on a per-module basis therefore you can easily locate the layout file to modify with the help of the Template Hints.

To enable Template Hints, go to System -> Configuration -> Advanced -> Developer. At this point you will need to make sure you have your website selected in the Current Configuration Scope dropdown instead of Default Config. Once your website is selected in the dropdown, click Debug. Here, you can change Template Path Hints to Yes. If you want even further information, you can also change Add Block Names to Hint to Yes.


------------------------------------------------------------------------

Remove some unwanted stuffs
Create a file named local.xml. Inside of local.xml, create a <default> block that will contain and consolidate your global changes:
<?xml version="1.0" ?>
<layout>
    <default> <!-- Your block overrides will go here -->
    </default>
</layout>

Depending on what you want to turn off, local.xml might contain some of the following lines.

<default>
    <remove name="left.permanent.callout" /> <!--the dog-->
    <remove name="right.permanent.callout" /> <!--back to school-->
    <remove name="catalog.compare.sidebar" /> <!--product compare-->
    <remove name="paypal.partner.right.logo" /> <!--paypal logo-->
    <remove name="cart_sidebar" /> <!--cart sidebar-->
    <remove name="left.reports.product.viewed" /> <!--recently viewed prod-->
    <remove    name="right.reports.product.viewed" /> <!--recently viewed prod-->
    <remove name="right.reports.product.compared" /> <!--recently compared prod-->
</default>


Tuesday, May 15, 2012

Customer and Product adapters



Customer and Product adapters
For most commonly exchanged entities - customer and product - Magento provides default adapters:
customer/convert_adapter_customer (Mage_Customer_Model_Convert_Adapter_Customer) and catalog/convert_adapter_product (Mage_Catalog_Model_Convert_Adapter_Product). Both inherit from Mage_Eav_Model_Convert_Adapter_Entity. To simply load all customers data for selected store you can use the following xml:

<action type="customer/convert_adapter_customer" method="load"> <var name="store">default</var> </action> Sometimes you may want to load only defined group of customers from database. To help you with this there are available following filtering variables: filter/firstname - to load only customers with firstname starting with value of this variable filter/lastname - to load only customers with lastname starting with value of this variable filter/email - to load only customers with email starting with value of this variable filter/group - to load only customers from group with id equal to value of this variable filter/adressType - to export only selected addressType; valid values are: both, default_billing, default_shipping filter/telephone - to load only customers with telephone starting with value of this variable filter/postcode - to load only customers with postcode starting with value of this variable filter/country - to load only customers with country iso code equal to value of this variable filter/region - to load only customers with region equal to value of this variable (for US just 2-letter state names) filter/created_at/from - to load only customers created after a date defined as value of this variable filter/created_at/to - to load only customers created before a date defined as value of this variable

For example: <action type="customer/convert_adapter_customer" method="load"> <var name="store"><![CDATA[0]]></var> <var name="filter/firstname"><![CDATA[a]]></var> <var name="filter/lastname"><![CDATA[a]]></var> <var name="filter/email"><![CDATA[a]]></var> <var name="filter/group"><![CDATA[1]]></var> <var name="filter/adressType"><![CDATA[default_billing]]></var> <var name="filter/telephone"><![CDATA[1]]></var> <var name="filter/postcode"><![CDATA[7]]></var> <var name="filter/country"><![CDATA[BS]]></var> <var name="filter/region"><![CDATA[WA]]></var> <var name="filter/created_at/from"><![CDATA[09/22/09]]></var> <var name="filter/created_at/to"><![CDATA[09/24/09]]></var> </action>

Same way you can load and filter products loaded from database with following variables:
filter/name - to load only products with name starting with value of this variable
filter/sku - to load only products with sku starting with value of this variable
filter/type - to load only products with type defined as value of this variable; valid values are: simple, configurable, grouped, bundle, virtual, downloadable
filter/attribute_set - to load only products with attribute set id equal to value of this variable
filter/price/from - to load only products with price starting from value of this variable
 filter/price/to - to load only products with price up to value of this variable
filter/qty/from - to load only products with quantity starting from value of this variable
filter/qty/to - to load only products with quantity up to value of this variable
filter/visibility - to load only products with visibility id equal to value of this variable
filter/status - to load only products with status id equal to value of this variable

Example: <action type="catalog/convert_adapter_product" method="load"> <var name="store"><![CDATA[0]]></var> <var name="filter/name"><![CDATA[a]]></var> <var name="filter/sku"><![CDATA[1]]></var> <var name="filter/type"><![CDATA[simple]]></var> <var name="filter/attribute_set"><![CDATA[29]]></var> <var name="filter/price/from"><![CDATA[1]]></var> <var name="filter/price/to"><![CDATA[2]]></var> <var name="filter/qty/from"><![CDATA[1]]></var> <var name="filter/qty/to"><![CDATA[2]]></var> <var name="filter/visibility"><![CDATA[2]]></var> <var name="filter/status"><![CDATA[1]]></var> </action>