Modules and Components Introduction in Joomla! 2.5

  • 2,334 views
Uploaded on

This presentation covers a basic introduction of modules and components in Joomla!

This presentation covers a basic introduction of modules and components in Joomla!

More in: Technology
  • Full Name Full Name Comment goes here.
    Are you sure you want to
    Your message goes here
    Be the first to comment
No Downloads

Views

Total Views
2,334
On Slideshare
0
From Embeds
0
Number of Embeds
1

Actions

Shares
Downloads
226
Comments
0
Likes
1

Embeds 0

No embeds

Report content

Flagged as inappropriate Flag as inappropriate
Flag as inappropriate

Select your reason for flagging this presentation as inappropriate.

Cancel
    No notes for slide
  • Hi, I am Vishwash Gaur. Today, I am going to present a beginner series webinar on the topic of Component and Module development in Joomla 2.5
  • There would be an added benefit if you have downloaded, installed and used Joomla! a little bit in prior.In reducing the procedural code issues i.e. lack of code reusability, higher debugging time and more
  • Modules typically makeup the elements of sidebar or content menus. Module complements the content contained in a component; they are not intended to be main sub-stance of the page.Modules are installed through the admin panel, they don’t manipulate any data from the database all what they do is display the contents on the page like examples on the page.
  • Module folder is located inside the modules directory of either front end or backend as per the case of development.
  • Components frequently have sophisticated back-end controls. The back-end is commonly used to create and manage the records from database. In Joomla, Content manager and Banner manager are examples of a component.Convention: Decide structure of component before development i.e. for front end, back end or both – it would allow you easy programming reference during the development.

Transcript

  • 1. Vishwash Gaur © 2012 Vishwash Gaur. All rights reserved.All registered trademarks, logos, products and service names belong to their respective owners. Image Credit: http://ayadipro.com/blog/high-tech-education/25-improvements-in-joomla-2-5/Disclaimer: Images used on this slide are for representative purposes only and belong to their respective owners.
  • 2.  Basic knowledge of HTML, PHP and MySQL Interest in MVC and CMS frameworks to reduce development time A web server with PHP/MySQL installed on it Joomla! 2.5 package downloaded and installed ◦ it can be downloaded from http://www.joomla.org/download.html NOTE: This presentation is focused for the beginners in Joomla! and would cover only a basic overview due to limited time. Further details can be discussed separately later.
  • 3. An overview of both theJoomla! Extensions tounderstand thebasics, conventions andstructure.
  • 4.  What is a module? ◦ Modules are lightweight and flexible extensions used for page rendering. These modules are often “boxes” arranged around a component on a typical page. A well-known example is the login module. Why should we use a module? ◦ Can work standalone ◦ Good for code reusability ◦ Can work with component for database linking Conventions ◦ Module name should be in small letters ◦ Module name should have a prefix “mod_”
  • 5.  Depends on template Added in template using below code: ◦ <jdoc:include type="modules" name=“module-positon- name" /> Can be more than one modules on a page
  • 6.  Go to Joomla! Admin Panel Access Top Menu>Extensions>Template Manager Click on options button on the top-right side of the toolbar Enable the “Preview module positions” Go to website front panel and add “?tp=1” to the url ◦ It will reveal the module positions in a Joomla template
  • 7. Go to template manager
  • 8. Click on options
  • 9. Enable setting to previewmodule positions
  • 10. http://yoursite.com/index.php?tp=1 Open your page with “?tp=1” at the end of url and it will reveal all Module positions
  • 11.  Mod_modulename – module folder ◦ mod_modulename.xml ◦ mod_modulename.php ◦ helper.php: This helper file contains a class to provide various static functions to perform operations. It could be used to perform some calculation or to fetch data from DB. ◦ index.html: It is an empty file and created to prevent direct access to the directory. ◦ tmpl folder  default.php:  index.html: It is an empty file and created to prevent direct access to the directory.
  • 12.  What is component? ◦ Components are the main functional units of Joomla!; they can be seen as mini-applications. ◦ A component can contain a module and a plug-in Why should we use a component? ◦ To manage more functional part or application ◦ To provide backend handling to a front-end functionality Conventions ◦ Component name should be prefixed by “com_” e.g. com_componentname ◦ Component name should start with small letters
  • 13.  Depends on template Added in template using below code: ◦ <jdoc:include type="component" /> Can be only one component on a page
  • 14. Image credit: http://www.slideshare.net/silenceit/joomlacontent-management-system
  • 15. Website Backend:Website Front-end: admin/index.htmlhelloworld.xml admin/helloworld.phpsite/index.html admin/controller.phpsite/helloworld.php admin/models/index.html admin/models/fields/index.htmlsite/controller.php admin/models/fields/helloworld.phpsite/views/index.html admin/models/forms/index.htmlsite/views/helloworld/index.html admin/models/forms/helloworld.xmlsite/views/helloworld/view.html.php admin/models/helloworld.php admin/models/helloworlds.phpsite/views/helloworld/tmpl/index.html admin/views/index.htmlsite/views/helloworld/tmpl/default.xml admin/views/helloworlds/index.htmlsite/views/helloworld/tmpl/default.php admin/views/helloworlds/view.html.php admin/views/helloworlds/tmpl/index.htmlsite/models/index.html admin/views/helloworlds/tmpl/default.phpsite/models/helloworld.php admin/views/helloworlds/tmpl/default_head.php admin/views/helloworlds/tmpl/default_body.php admin/views/helloworlds/tmpl/default_foot.php admin/views/helloworld/index.html admin/views/helloworld/view.html.php admin/views/helloworld/tmpl/index.html admin/views/helloworld/tmpl/edit.php admin/tables/index.html admin/tables/helloworld.php admin/language/en-GB/en-GB.com_helloworld.ini admin/language/en-GB/en- GB.com_helloworld.menu.ini admin/controllers/index.html admin/controllers/helloworld.php admin/controllers/helloworlds.php
  • 16.  I look forward to learn and share more with you in future too. I can be reached easily at my blog www.vishwashgaur.com and/or using twitter @vishwashgaur
  • 17.  XAMP: http://www.apachefriends.org/en/xampp.html Joomla!: http://www.joomla.org/ JED: http://extensions.joomla.org/ Joomla! Forum: http://forum.joomla.org/ Joomla! Magazine: http://magazine.joomla.org/authors/itemlist/user/65-Nicholas-G-Antimisiaris Joomla documentation: http://docs.joomla.org/ Joomla 2.5 essential training: http://www.lynda.com/Joomla-tutorials/Joomla-Essential-Training/95699-2.html Joomla! For beginners guide 2012: http://www.danconia.com/joomla-for-beginners-guide-2012.html Joomla! Developers guide: http://cocoate.com/sites/cocoate.com/files/private/jdev.pdf