Sign In Start Free Trial
Account

Add to playlist

Create a Playlist

Modal Close icon
You need to login to use this feature.
  • Book Overview & Buying Mastering Magento Theme Design
  • Table Of Contents Toc
Mastering Magento Theme Design

Mastering Magento Theme Design

By : Andrea Sacca
4.2 (5)
close
close
Mastering Magento Theme Design

Mastering Magento Theme Design

4.2 (5)
By: Andrea Sacca

Overview of this book

Table of Contents (18 chapters)
close
close
Mastering Magento Theme Design
Credits
About the Author
About the Reviewers
www.PacktPub.com
Preface
2
Index

Developing a widget


The method of developing a widget does not differ much from that of developing a regular Magento module. In a few words, a Magento widget is a Magento module that generates admin add-ons, which you can easily insert into CMS pages or CMS blocks with simple actions.

We will start by creating a sample module that provides one simple widget.

The widget called Social Widget Icons outputs a block that includes the AddThis social sharing icons, the same sharing icons that we added in Chapter 6, Making the Theme Socially Ready.

The final frontend result is shown by the following screenshot:

Creating an empty module

Let's start by creating the module's directory structure and the main files. The module folder must be located into app/code.

Here, you have to decide in which code pool you want to create the module. Usually, you can create your module under the local code pool.

Tip

Never create a module inside the core folder of Magento and never edit the files inside the core. It can...

CONTINUE READING
83
Tech Concepts
36
Programming languages
73
Tech Tools
Icon Unlimited access to the largest independent learning library in tech of over 8,000 expert-authored tech books and videos.
Icon Innovative learning tools, including AI book assistants, code context explainers, and text-to-speech.
Icon 50+ new titles added per month and exclusive early access to books as they are being written.
Mastering Magento Theme Design
notes
bookmark Notes and Bookmarks search Search in title playlist Add to playlist font-size Font size

Change the font size

margin-width Margin width

Change margin width

day-mode Day/Sepia/Night Modes

Change background colour

Close icon Search
Country selected

Close icon Your notes and bookmarks

Confirmation

Modal Close icon
claim successful

Buy this book with your credits?

Modal Close icon
Are you sure you want to buy this book with one of your credits?
Close
YES, BUY

Submit Your Feedback

Modal Close icon
Modal Close icon
Modal Close icon