Child pages
  • Managing Modules and Themes

Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Table of Contents
maxLevel3
styledisc
printablefalse

Managing Modules

...

Modules

PrestaShop 1.4 comes bundled with over 110 modules that can be installed/uninstalled and configured as desired, so as to customize and complete your shop. The range of actions is virtually unlimited: the extensibility of PrestaShop makes it possible to turn your shop into exactly what you intend it to do, instead of you having to comply with constraints that you didn't choose – provided you can find the module that does exactly what you need.

...

Most of the time, warnings are a reminder that you haven't properly configured the module. Click their "Configure" link and go through the various needed steps.

Modules And Themes Catalog

PrestaShop comes bundled with a host of modules, but even that number might seem limiting, or you could want to explore other directions.

...

The "Modules & Themes Catalog" gives you a quick and easy access to the Addons database of modules and themes. A search query will return the 5 first results from Addons, with more available if you click on the "View all results on addons.prestashop.com" link.

Installing modules

Once you have downloaded a module from the Addons online store, it's up to you have it installed on your PrestaShop site.

There are two ways to install a module: either using the dedicated form, or using your FTP client.

Installing using the dedicated form

To install a new PrestaShop module "automatically", click on the "Add a module from my computer" link at the top of the list of modules. This will reveal a new section.

...

Once validated, PrestaShop will load the module (either from the Web or from your computer), unpack it, place the files in the correct location, and update the page, all this in a handful of seconds.

Installing using an FTP client

To install a new PrestaShop module manually:

...

Once configuration is complete, be sure to test the module immediately to confirm that it works as planned.

Uninstalling a module

If you only need to temporarily not use the module, but still wish to keep its configuration, you can simply disable it: just click on the green tick, which should then turn into a red cross, meaning that the module is still installed, but disabled.

...

If you changed your theme to take the module into account, make sure that the disabling or removal of the module does not break the theme.

My Account

PrestaShop also enables you to access your Addons account right from the back-office.

...

Log-in using the form on the "My Account" sub-tab, and get access to all your Addons details.

Positions

The order in which modules' front-office interface are displayed can be customized – because you might want one module to be place much higher (or lower) in the page that others. In PrestaShop's jargon, this is called "transplanting", and is done using the tool available under the "Positions" sub-tab for the "Modules" tab. In effect, this enables you to attach a module to one of the many available hooks in the current theme, without writing any code.

...

Each hook's table displays the hook's name, its technical name, its number of attached modules, and finally lists the attached modules themselves.
For each module, you have access to its position relative to this hook.

Moving a module

You have two ways of moving a module within a hook:

...

For most modules, transplantation can easily be done directly via the Back Office. Certain modules require altering the code in order to transplant the module.

Transplanting a module via the back-office

  1. Go to the "Modules" tab, and its "Positions" sub-tab.
  2. Click the "Transplant a module" link.
  3. In the "Module" drop-down menu, select the module you want to transplant.
  4. In the "Hook Into" drop-down menu, select where you want to transplant the module to.
  5. In the "Exceptions" field, type the name of the file(s) of the pages in which you do not want the module to appear.
  6. Click the "Save" button.

The "Hook Into" drop-down menu gives you a good idea where module can be placed.

Transplanting a module by modifying its code

Some modules cannot be transplanted into other page sections because they lack the necessary code. For example, the Quick Search block contains templates for both column display and header display, while the Currencies block only has one template file which only pertains to the header section. Likewise, the default Featured Products block can only be placed in the center content section of the main page. If you want to move it to a column, you'll have to do the customization yourself.

...

...and edit its PHP, HTML and CSS code accordingly.

Live Edit

Another way to move modules around on the shop's homepage is the Live Edit mode, which embeds said homepage into a tool that lets you graphically decide where to place your modules. You can access it from the "Position" sub-tab, by clicking the "Run LiveEdit" button.

...

The first one is quite self-explanatory; the second one cancels all changes you might have made to your modules during this live-editing session. Note that once you have clicked after having removed a module, you'll have to go to the "Positions" sub-tab and use the "Transplant a module" form in order to bring it back.

Where to move modules

Modules cannot be moved just about anywhere: it depends on both the theme's hooks, and each module's hook support (as seen in the above section). Therefore, you mostly can only move modules within their understood context: column modules can be moved within a column as well as from one column to the other (right to left, for instance), while regular homepage modules (the ones at the center) can only be moved within their specific column.

In order to give you a visual hint about where a given module can be moved, it will display an empty green block if the location is correct, and an empty red block if not.

Payment

With PrestaShop, you can accept your customer's transactions through several different payment methods, such as checks, bank wire, cash on delivery, Google Checkout, and some partner modules such as Hipay, Moneybookers, and PayPal. They are already included in your store and are ready to be used. However, it is necessary to configure them.

Installing a payment module

Let's install the "Cash on delivery" module. You first need to access the list of payment modules. It is of course accessible via the "Modules" tab, under the "Payments and Gateways" section, but you also have a shortcut from within the "Payment" tab: just click on the appropriate button at the top of the page!

...

Find the "Cash on delivery (COD)" module in the list (third row). To install it, you just need to click on the "Install" button.

Payment Module Restrictions on Currencies

When in the "Payment" tab, you can see the following section:

...

Another option is that you can only accept payment with the store's default currency (which you can set in the "Payment" tab, "Currencies" sub-tab, "Currency options" setting).

Payment Module Restrictions on Groups

You can limit the choice of payment method depending on the group of customers.

...

For instance, let's say you would prefer that individuals pay with PayPal, Moneybookers and Hipay, while professionals only pay by bank wire. Depending on the type of customer and on your choices, customers will only pay using the methods that match with your decisions.

Payment Module Restrictions on Countries

You can limit the choice of payment methods according to your customer's country of origin. For instance, in France, Spain, and Germany, you can accept all payment methods, while customers in Italy, the United Kingdom or Switzerland can only pay by bank wire.

...