Magento Resource | E-Commerce Generation Explorer

CAT | design

Jul/09

26

Magento Showcase

Here are some sites developed by MAGENTO.

www.londonoflinks.co.uk/

www.inspiredoffice.co.uk

www.whiteboardstore.co.uk

www.grasscity.com/

www.gap.com/

www.kapitolreef.com

www.Gutes-Guenstiger.com

www.billetgrillpro.com/
(more…)

· ·

This may a simply question, but I still want point out where can fully disable module, so you need go to module config file, like /etc/YourMyModule.xml, and set the active parametar to false, like:

1
2
3
4
5
6
7
8
9
<?xml version='1.0'?>
<config>
<modules>
<YourMyModule>
<active>false</active>
<codepool>local</codepool>
</YourMyModule>
</modules>
</config>

All done!

·

The file you need to look at is: /app/code/core/Mage/Catalog/Block/Product/List/Toolbar.php. Please do a backup for this file first.

On there, you will notice these codes at the beginning of the file:

1
2
3
4
5
$this->_availableOrder = array(
'position'  => $this->__('Best Value'),
'name'      => $this->__('Name'),
'price'     => $this->__('Price')
);

Default order takes the first value available(The first one is the system automatic load one).

So, all you need to do is:
•reorder it if you want to have a selection in the Toolbar or
•set only one value of choice if you will remove the selection from the toolbar

For example, if you want sort by SKU, just simply update it to:

1
2
3
4
5
$this->_availableOrder = array(
'position'  => $this->__('SKU'),
'name'      => $this->__('Name'),
'price'     => $this->__('Price')
);

Hope this can help someone.

· ·

On the ADMIN page,

1. Download the desired translation thru Magento connect via admin.
2. Once installed Go to: System -> Manage Stores -> Create store view. Enter the data and save.
3. Now go to: Configuration -> Current Configuration Scope (Select your language from the dropdown) and on the right side under “Locale options” choose the desired language.

Note: Please clear the cache before trying to use the new language.

Now, on the frontpage, you’ll notice a dropdown menu allowing the language switching.

·

If the magento, there are many built-in features are not useful to you or to your customers you can always disable them via the admin interface by disabling their respective modules.

Wishlist is not one of them.

To remove all of the traces of the wishlist functionality you need to do the following:

1. Go to the Admin interface (select the appropriate scope) and under System -> Configuration -> Customers -> Whishlist select “No” under the “Enabled” in the General options.

This will remove all of the whishlist links in the magento blocks as well as the whishlist itself.

2. (your template name)/template/catalog/product/view/addto.phtml and remove the “pipe” character from that file so that it doesn’t disturb the looks of your site

3. Go to: System -> Configuration ->Advanced->Advanced and set disable “Mage_Whishlist”

That’s it. All Done!

· ·

Here is a tutorial for how to add login form on the Home page.

Open customer.xml from layout folder, and find (around line 91)

1
2
3
<reference name=”content”>
<block type=”customer/form_login” name=”customer_form_login” template=”customer/form/login.phtml”/>
</reference>

Then open cms.xml and find (around line 46)

1
2
3
<reference name=”content”>
<block type=”cms/page” name=”cms_page”/>
</reference>

(more…)

· · ·

Jun/09

25

What’s in a block?

Many developers are familiar with the MVC (Model View Controller) design pattern that is seemingly ubiquitous throughout web frameworks. Looking through the code in Magento, however, we see many other components besides the M’s the V’s and the C’s.

Each module  (a “module” meaning the separate directories within the “app/code/core/Mage” directory that comprise of Magento’s different functional areas) contains the usual Controller and Model. You’ll see that within each module, there are no Views (more on this later). You’ll also see extra tidbits, such as “helper” , “etc” and “sql”. These are (and are not) standard within the Zend Framework context and will not be discussed in this article. In these modules are also the sort of files which we work with very often. The all powerful block! This article will attempt to (hopefully accurately) describe just what a Block is and how it’s used.

A top priority of (good) Object Oriented Programming is the decoupling of code. In a nut shell, this means that code should have the least amount of dependency on other code as possible. (Slightly more accurately, objects should not rely too heavily on other objects to exist and function). Blocks are part of Magento’s solution to keep their application loosely coupled.

(more…)

·

Here is a solution for: How to move the cart sidebar into the header area or anywhere you want.

1) Copy the the block for the cart side bar:
\design\frontend\default\default\layout\checkout.xml

1
<block type="checkout/cart_sidebar" name="cart_sidebar" template="checkout/cart/sidebar.phtml"/>

(more…)

No tags

How to use PHP on a CMS page (MAGENTO custom Block/module)
Here is a guide to explain how to use PHP on a CMS page.
This involves creating and/or extending and/or overriding a controller class.
Here are the basic instructions to create a custom module:

1. Declare the module: app/etc/modules/YourModule_All.xml

1
2
3
4
5
6
7
8
9
< ?xml version="1.0"?>
<config>
<modules>
<yourmodule_custom>
<active>true</active>
<codepool>local</codepool>
</yourmodule_custom>
</modules>
</config>

(more…)

· ·

For Footer Area, we need edit two different locations.
One part is a static block which created within the magento admin area (CMS > Static Block).

The other part is held as .phtml / .php / .xml files within the design files.

XML files location:
app/design/frontend/*/*/layout/page.xml

Here you will find some footer reference:

1
2
3
4
<block type="page/html_footer" name="footer" as="footer" template="page/html/footer.phtml">
<block type="page/switch" name="store_switcher" as="store_switcher" template="page/switch/stores.phtml"/>
<block type="page/template_links" name="footer_links" as="footer_links" template="page/template/links.phtml"/>
</block>

Another XML files location:
app/design/frontend/*/*/layout/cms.xml

(more…)

· ·

<< Latest posts

Theme Design by devolux.nh2.me