Search icon CANCEL
Arrow left icon
Explore Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Conferences
Free Learning
Arrow right icon
Arrow up icon
GO TO TOP
Mastering Magento Theme Design

You're reading from   Mastering Magento Theme Design Magento is the super-capable open source e-commerce platform that's number one for a reason. By using this book to optimize your know-how, you'll be acquiring the ultimate in e-tail expertise for yourself and your clients.

Arrow left icon
Product type Paperback
Published in Apr 2014
Publisher
ISBN-13 9781783288236
Length 310 pages
Edition Edition
Languages
Tools
Concepts
Arrow right icon
Author (1):
Arrow left icon
Andrea Sacca Andrea Sacca
Author Profile Icon Andrea Sacca
Andrea Sacca
Arrow right icon
View More author details
Toc

Table of Contents (18) Chapters Close

Mastering Magento Theme Design
Credits
About the Author
About the Reviewers
www.PacktPub.com
Preface
1. Introducing Magento Theme Design FREE CHAPTER 2. Creating a Responsive Magento Theme with Bootstrap 3 3. Customizing Our Custom Theme 4. Adding Incredible Effects to Our Theme 5. Making the Theme Fully Responsive 6. Making the Theme Socially Ready 7. Creating a Magento Widget 8. Creating a Theme Admin Panel 9. Customizing the Backend of Magento 10. Packaging and Selling the Theme Conclusions and Credits Index

Integrating the code in the product page


Let's suppose that we want to add the code only in the product page. To do this, perform the following steps:

  1. Go to your theme folders and create a file called addthis.phtml in app/design/frontend/bookstore/default/template/social.

  2. Paste the copied code, as mentioned in the previous section, in the file and save it.

  3. Now, we need to open the local.xml file and find the <catalog_product_view> product view handle (for your reference, this handle is defined first inside the catalog.xml file of the base theme in app/design/frontend/base/default/layout) and inside it, in <reference name="content">, add the following code that will declare a core/template block to be displayed on the product page:

    <reference name="content">
    <block type="core/template" name="socialsharing" template="social/addthis.phtml" before="-" />
    </reference>

    Now, open the file of the product page, view.phtml, located in app/design/frontend/bookstore/default...

lock icon The rest of the chapter is locked
Register for a free Packt account to unlock a world of extra content!
A free Packt account unlocks extra newsletters, articles, discounted offers, and much more. Start advancing your knowledge today.
Unlock this book and the full library FREE for 7 days
Get unlimited access to 7000+ expert-authored eBooks and videos courses covering every tech area you can think of
Renews at €18.99/month. Cancel anytime