Magento (Community Edition) with module analysis and in the domestic use of recommendations one

Source: Internet
Author: User
Tags oauth

This chapter begins by parsing Magento1 's own modules, which are described in different ways depending on the complexity and importance of the module, some using only text, and some with.


As the literal meaning, the admin module is related to the background administrator, specifically, the background user (Admin_user table) and the background user's rights management (Admin_role and Admin_rule table). To version,

For security reasons added Permission_variable and Permission_block features, this is not detailed, see release-notes.

It's a bit far, magento. The permission function is based on the ACL model, and there is another widely used access control model called RBAC in the market. Although the ACL generally can meet the needs of Magento background management, but combined with the actual work encountered in the situation, the RBAC model may be more in line with an e-commerce site management needs, such as the "Customer service supervisor" and "General customer service" level structure of the permission distribution requirements.

There is no doubt that this module is the cornerstone of the background that must be opened.


The actual function of this module is almost the meaning of the background notice. Notification of the presentation of two kinds of minutes, one is the banner display in the Background main menu bar, another way is to log in the background when the pop-up window.

The content of the notification is about the following: website health (such as cache expiration, index not updated, etc.), Magento official push notifications (such as the new version, what the official event, etc.), the installation of the third-party plug-in companies to push the information (such as the installation of the plugin has a new version, Or, for example, the sale of such sales information).

The adminnotification module can theoretically be closed without affecting the normal operation of the front and rear stations. You will no longer receive these notifications when you close them, avoid harassment and also lose the ability to get valuable notifications, and of course, the loss of notice will not have much impact, such as the people who are concerned about the Magento themselves will occasionally be concerned about the official release of the new version.

So, this module is off or not, optional.


Adminhtml is an incredibly large module with over 500 folders and more than 1000 files in the entire directory. Although this is so large, the role of this module is very good explanation, that is almost the entire background of the content (not counted third-party plug-ins) are controlled by adminhtml .

Here is a code structure of doubt, Magento function by module Division of the practice is accepted by most people, to reduce the coupling of the entire system is very useful. The adminhtml module is the only one that sets the background management of all functions together, turning the module into a monster. Theoretically magento can be different function blocks of the background management code to the respective module directory, such as commodity Management code can be written to the catalog module, this looks like the system is more complete modularization (such as third-party plug-in if there is a part of the background management, The code behind the scenes is naturally written in the directory of its own module.

Magento officials may have their own consideration, at least for background changes and two development, can be found in a module all the background source code is also a convenience.

adminhtml module Of course is must be opened, do not open the backstage.


Magento's first type of Interface module (earlier version only of this type), provides XML-RPC and soap Two interface protocols, the two protocols same strain, for already encapsulated Magento, a new interface only need to develop a set of code, you can simultaneously support XML-RPC and SOAP two protocols.

Soap is a set of interface protocols that are not yet young, but are still widely used, and basically all popular programming languages have a ready-made class library that supports soap.

In addition to the Protocol encapsulation, the API module provides ACL model-based interface resource rights allocation, can be used in the background to specify the different interface users have different access rights (such as a user only allow access to 1, 2, 3 interface functions, B users only allow access to 4, 5, 6 interface functions), This is quite good for the information and data security of the website.

API modules do not have to be opened, if there is no need to open the interface. Of course, the actual operation of the Magento site, there should be a large proportion of the needs of docking with other systems, this time, after the system at the bottom of the package, on the Magento to develop a new interface is still very convenient.


Magento's two types of interface modules ( new for later versions )provide RESTful API interface support.

Similar to API modules, the API2 module also encapsulates the interface, and also provides the ability to assign interface resources through the background.

For the authorization of the RESTful API, Magento is implemented using the popular OAuth protocol, which is matched by another module in the system, and the name of the module is called OAuth.

Similarly, the Api2 module is optional, depending on whether or not you will need to use the system docking. There is no interdependence between the API2 module and the API module, which can be used individually, together or two modules.


The AuthorizeNet module is very well understood to be a Native American payment gateway (similar to PayPal, see It is not clear how popular authorizenet is in the United States, certainly not the PayPal epidemic. If it is to do domestic Chinese station, it will certainly not use this module, decisively close it.


The backup module provides a visual interface in the background for backing up websites, choosing to back up (and restore) Web site files or backing up databases, and so on. The files generated by the backup are placed in the Var/backups directory.

Common site backup operations are typically performed by operations personnel through a scheduled script on the server. Although the Magento Backup module also provides the ability to regularly back up data via the system's cron mechanism, it can back up (and especially restore) the website directly through the background operation. It's not very safe to feel (although you can also use background permissions to control the general background user is not authorized to operate), I personally do not recommend this way.

If you do not need to back up the site, or if you put the backup site as mentioned in operation, then turn off this backup module.


Magento Native offers 6 commodity types, one of which is bundled product (bundle product). Of the 6 types,Bundle product and downloadable product are controlled independently of one module, while the other 4 types are in the Catalog module.

Bundle Product is similar to another type of grouped products, which provides the ability to combine packaged purchases, except that bundle product provides a more complex combination of methods, As well as the free set up after the price of the product (such as the top plus pants combination buy than buy a discount 20, etc.). See: Magento grouped vs bundle products

The function of the bundled goods in a lot of scenes or used to get, of course, this also look at the site specific types of goods sold (clothing or food) and sales methods. One problem here is that The bundled goods function can only be a simple commodity (simple Product ", and the actual application seems to have a number of configurable product bundle selling requirements. PS: There seems to be a third-party plugin to meet this requirement If you do not need or temporarily do not use this function, you can turn off the bundle module (this time reflects the bundling of goods alone to make a module of the benefits).
9. CaptchaVerification code module, can be used in the background login and retrieve password.
NativeCase can only be used in the background (do not exclude two times after development for the foreground). About this module is open or not, I am not sure how the foreigner's aesthetic, at least in the domestic, with the domestic web site common verification code compared to the Magento of this set of verification code generated by the figure is a bit ugly. So if you don't use this function, turn off the Captcha module. If it is necessary to use the verification code (I mean the domestic), it is suggested to find a more in line with the Chinese aesthetic Code of the class library, its own based on the class library on the Magento to do the verification code function.
10. CatalogThe "Commodity" (as well as the user and order) of one of the most basic components of e-commerce is controlled mainly by the catalog module. Slightly more specifically, this module manages the content of categories, commodities, commodities, and most of the control codes that are associated with the display of the product at the foreground. For Magento systems, this is a core module and one of the few modules most familiar to all Magento users. I'm just an overview of the module, so forThe catalog module does not seem to have anything special to say about it. the Catalog module, of course, must be turned on.
The above is the first part of this series, a brief summary of the above 10 modules, one of the admin,adminhtml,catalog Three modules is must be opened (site normal operation of the foundation), Adminnotification,api,api2,bundle can be selected according to the needs of the optional to do not open, Authorizenet,backup and captcha My advice is to close (for doing domestic Chinese station). As mentioned before, this series is an overview, so the description of most modules is a cursory, because each module to be clear can be written in a separate article (or even a number of articles). The description of the above 10 modules is based on my personal understanding, if there is a description of the wrong place, please correct me.

Magento (Community Edition) with module analysis and in the domestic use of recommendations one

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.