Mastering Joomla! 1.5 Extension and Framework Development Second Edition


Mastering Joomla! 1.5 Extension and Framework Development Second Edition
eBook: $29.99
Formats: PDF, PacktLib, ePub and Mobi formats
$25.49
save 15%!
Print + free eBook + free PacktLib access to the book: $79.98    Print cover: $49.99
$49.99
save 37%!
Free Shipping!
UK, US, Europe and selected countries in Asia.
Also available on:
Overview
Table of Contents
Author
Reviews
Support
Sample Chapters
  • In-depth guide to programming Joomla! 1.5 Framework
  • Design and build secure and robust components, modules, and plugins
  • Customize the document properties, add multilingual capabilities, and provide an interactive user experience
  • Includes a comprehensive reference to the major areas of Joomla!’s common classes, variables, and constants crucial for creating Joomla! Extensions.

Book Details

Language : English
Paperback : 560 pages [ 235mm x 191mm ]
Release Date : May 2010
ISBN : 1849510520
ISBN 13 : 9781849510523
Author(s) : Chuck Lanham, James Kennard
Topics and Technologies : All Books, CMS and eCommerce, Content Management (CMS), Joomla!, Open Source, Web Development

Back to BOOK PAGE

Table of Contents

Preface
Chapter 1: Introduction to Joomla!
Chapter 2: Getting Started
Chapter 3: The Database
Chapter 4: Component Design
Chapter 5: Module Design
Chapter 6: Plugin Design
Chapter 7: Extension Design
Chapter 8: Rendering Output
Chapter 9: Customizing the Page
Chapter 10: APIs and Web Services
Chapter 11: Error Handling and Security
Chapter 12: Utilities and Useful Classes
Appendix
Index
  • Chapter 1: Introduction to Joomla!
    • Overview
    • History
    • Requirements
    • Extension Types and Their Uses
      • Components
      • Modules
      • Plugins
      • Languages
      • Templates
      • Tools
    • Extension Manager
    • JED and JoomlaCode.org
    • Development Tools
      • J!Code
      • J!Dump
    • Summary
  • Chapter 2: Getting Started
    • The Application and Document
    • Request to Response
      • The Process
    • URI Structure
    • Directory Structure
    • Libraries
    • A Quick Lesson in Classes
      • Inheriting from JObject
    • Working with the Request
    • The Factory
    • The Session
    • Predefined Constants
    • Multilingual Support
      • UTF-8 String Handling
    • Coding Standards
      • phpDocumentor
    • Summary
  • Chapter 3: The Database
    • The Core Database
    • Extending the Database
      • Table Prefix
      • Schema Conventions
        • Common Fields
        • Schema Example
      • Dealing with Multilingual Requirements
    • Querying the Database
      • Writing Queries
      • Getting Results
        • loadResult( ) : string
        • loadResultArray( numinarray : int=0 ) : array
        • loadAssoc( ) : array
        • loadAssocList( key : string='' ) : array
        • loadObject( ) : stdClass
        • loadObjectList( key : string='' ) : array
        • loadRow( ) : array
        • loadRowList( key : int ) : array
      • Using ADOdb
    • JTable
      • CRUD
      • Manipulating Common Fields
        • Publishing
        • Hits
        • Checking Out
        • Ordering
        • Parameter Fields
        • Date Fields
    • Summary
  • Chapter 4: Component Design
    • Setting up a Sandbox
    • The Structure
    • The MVC
      • Building a Model
      • Building a View
      • Building a Controller
      • Building an MVC Component
    • Rendering Other Document Types
      • Feed
      • PDF
      • Raw
    • Dealing with Component Configuration
    • Elements and Parameters
      • Extending JElement
      • Using Custom JElement Classes
    • Help Files
    • Routing
    • Packaging
      • XML Manifest File
      • SQL Install and Uninstall Files and Queries
      • Install and Uninstall Files
    • Summary
  • Chapter 5: Module Design
    • Setting Up a Sandbox
    • First Steps
      • Standalone Modules
      • Modules and Components Working Together
      • Frontend and Backend Module Display Positions
    • Module Settings (Parameters)
    • Helpers
    • Layouts (Templates)
      • Media
    • Translating
    • Packaging
      • XML Manifest File
    • Summary
  • Chapter 6: Plugin Design
    • Setting Up a Sandbox
    • Events
    • Listeners
      • Registering Listeners
      • Handling Events
    • Plugin Groups
      • Authentication
      • Content
      • Editors
      • Editors-xtd
      • Search
      • System
      • User
      • XML-RPC
    • Loading Plugins
    • Using Plugins as Libraries (in Lieu of Library Extensions)
    • Translating Plugins
    • Dealing with Plugin Settings (Parameters)
    • Packaging
      • XML Manifest File
      • File Naming Conflicts
    • Summary
  • Chapter 7: Extension Design
    • Supporting Classes
    • Helpers
    • Using and Building getInstance() Methods
    • Using the Registry
      • Saving and Loading Registry Values
  • The User
    • User Parameters
  • The Session
  • The Browser
  • Assets
  • Summary
  • Chapter 8: Rendering Output
    • The joomla.html Library
      • Behavior
      • Email
      • Grid
      • Image
      • List
      • Menu
      • Select
    • Building Component HTML Layouts (Templates)
      • Iterative Templates
    • Component Backend
      • Admin Form
      • Toolbar
      • Sub-Menu
    • Itemized Data
      • Pagination
      • Ordering
      • Filtering and Searching
    • Summary
  • Chapter 9: Customizing the Page
    • Application Message Queue
    • Redirects
      • Component XML Metadata Files and Menu Parameters
    • Using Menu Item Parameters
    • Modifying the Document
      • Page Title
      • Pathway/Breadcrumb
      • JavaScript
      • CSS
      • Metadata
      • Custom Header Tags
    • Translating
      • Translating Text
      • Defining Translations
      • Debugging Translations
    • Using JavaScript Effects
      • JPane
      • Tooltips
      • Fx.Slide
    • Summary
  • Chapter 10: APIs and Web Services
    • XML
      • Parsing
      • Editing
      • Saving
    • AJAX
      • Response
      • Request
    • LDAP
    • Email
    • File Transfer Protocol
    • Web Services
    • Building a Web Service (XML-RPC Plugin)
    • Summary
  • Chapter 11: Error Handling and Security
    • Errors, Warnings, and Notices
      • Return Values
      • Customizing Error Handling
    • Dealing with CGI Request Data
      • Preprocessing CGI Data
      • Escaping and Encoding Data
        • Escaping and Quoting Database Data
        • Encode XHTML Data
      • Regular Expressions
        • Patterns
        • Matching
        • Replacing
    • Access Control
      • Menu Item Access Control
      • Extension Access Control
    • Attacks
      • How to Avoid Common Attacks
        • Using the Session Token
        • Code Injection
        • XSS (Cross Site Scripting)
        • File System Snooping
      • Dealing with Attacks
        • Log Out and Block
        • Attack Logging
        • Notify the Site Administrator
    • Summary
  • Appendix
    • Classes
      • JObject
        • Properties
        • Constructors
        • Methods
      • JUser
        • Properties
        • Constructors
        • Methods
      • JModel
        • Properties
        • Constructors
        • Methods
      • JView
        • Properties
        • Constructors
        • Methods
      • JController
        • Properties
        • Constructors
        • Methods
      • JTable
        • Properties
        • Constructors
        • Methods
      • JError
        • Methods
      • JDocument
        • Properties
        • Constructors
        • Methods
      • JApplication
        • Properties
        • Constructors
        • Methods
      • JURI
        • Properties
        • Constructors
        • Methods
      • JLanguage
        • Properties
        • Constructors
        • Methods
      • JLanguageHelper
        • Methods
      • JText
        • Methods
      • JElement
        • Properties
        • Constructors
        • Methods
      • JParameter
        • Properties
        • Constructors
        • Methods
      • JCache
        • Properties
        • Constructors
        • Methods
      • JMail
        • Constructors
        • Methods
      • JMailHelper
        • Methods
      • JFactory
        • Methods
      • JRegistry
        • Properties
        • Constructors
        • Methods
      • JSession
        • Properties
        • Constructors
        • Methods
      • JRoute
        • Methods
      • JMenu
        • Properties
        • Constructors
        • Methods
      • JPathway
        • Properties
        • Methods
      • JDatabase
        • Properties
        • Constructors
        • Methods
    • Parameters (Core JElements)
    • Configuration
Back to BOOK PAGE

Chuck Lanham

Chuck Lanham began his career as a database software engineer with Burroughs Corp. He later worked for Informix Corp. managing the database tools development group while serving as repository architect. He has founded and managed two successful software development companies, and taught college courses on database theory, data communications, and computer technologies. He has also managed the global development and deployment of leading CRM and CMS systems for many Fortune 500 companies, and managed the development and deployment of some of the largest e-commerce websites in the world.

In 2002, Chuck left the corporate world and started a new company, Blue Water Associates. This company is located near the deep blue waters of Lake Tahoe where he designs, develops, and maintains websites for small to medium sized businesses, both within the U.S. and abroad.

Chuck has been developing websites using Joomla! since 2007 with the release of version 1.5 and has developed several extensions for use in the websites he has designed. This is Chuck's first book as an author, although he has reviewed and edited several books and written numerous technical articles for publication.


James Kennard

James Kennard is a computer programmer. He has worked with various PHP and MySQL applications, since 2002. He quickly discovered Mambo/Joomla! because of its flexible extension manager. James currently maintains one open-source Joomla! component, which has been translated into over fifteen languages. Moreover, he has plans to build two more open-source components. Examples of his work can be found on his personal website www.webamoeba.co.uk.

Code Downloads

Download the code and support files for this book.


Submit Errata

Please let us know if you have found any errors not listed on this list by completing our errata submission form. Our editors will check them and add them to this list. Thank you.


Errata

- 3 submitted: last submission 21 May 2012

Errata type: Technical | Page number: 60, 78

In the last piece of code the checkin-method uses a user-id as a parameter. That should be a record-id (or can be left away if the buffered record is to be checked in).

The code should be:

$table->load($id);
if (!$table->checkin($id))
{
// handle failed to checkin record
}



Or simply:

if(!$table->checkin())
{
// handle failed to checkin record
}


If the buffered record is the one being checked in.

 

 

Errata type: Technical | Page number: 164-175

In the code a checkout() is missing. On page 175 the record is checked in (in the store()-method of the Revues-model of the Boxoffice-component). But it was never checked out in the code, neither in a model, nor in the controller.

There is no checkout() function in the code, although there is a checkin() call. This is really just an oversight and could easily be remedied by adding a bit of code to the controller and the model. A good example can be found in the administrator/components/com_weblink/models/weblink.php code -- isCheckedOut() and checkout() functions and administrator/components/com_weblink/controller.php – display() function.

 

Errata type: Technical | Page number: 59

 

$query = 'SELECT * FROM '.$db->nameQuote('contacts');
$db =& JFactory::getDBO();
$db->setQuery($query, 1, 20);
$result1 = $db->query($query);
$result2 = $db->query($query);


In this code, you are using the object $db before calling the JFactory::getDBO() function.
It should be:

 

$db =& JFactory::getDBO();
$query = 'SELECT * FROM '.$db->nameQuote('contacts');
$db->setQuery($query, 1, 20);
$result1 = $db->query($query);
$result2 = $db->query($query);

 

 

Sample chapters

You can view our sample chapters and prefaces of this title on PacktLib or download sample chapters in PDF format.

Frequently bought together

Mastering Joomla! 1.5 Extension and Framework Development Second Edition +    LabVIEW Graphical Programming Cookbook =
50% Off
the second eBook
Price for both: £29.05

Buy both these recommended eBooks together and get 50% off the cheapest eBook.

What you will learn from this book

  • Understand the structure and design of the Joomla! 1.5 framework and how it operates at its core to develop efficient and well-designed extensions for Joomla! 
  • Extend the database conventions for the database schema and common fields
  • Access and manipulate the database with the help of JDatabase and JTable classes
  • Design extensions that work within the Joomla! structure
  • Incorporate User, Session, Request, and Browser classes in extensions
  • Organize your code with the Model-View-Controller (MVC) design pattern
  • Build your own components to manage and present a specific set of data
  • Enhance our component by creating a module, which will add new functionality to our frontend
  • Modify your system’s functionality without the need to alter existing code
  • Discover how to add pagination, ordering, filtering, and searching to make your extensions more user-friendly, and increase the chances of having successfully created a commercially winning or freely available extension
  • Improve your extensions by customizing the document properties, adding multilingual capabilities, and providing an interactive user experience
  • Access remote third-party services from an application with Joomla!’s API (Application Programming Interface) and web service
  • Master the techniques of error handling and access control to prevent malicious attacks on your systems

In Detail

Joomla! is one of the world’s top open source content management systems, which enables you to build websites and powerful online applications. Out of the box, Joomla! does a great job of managing the content needed to enhance the functionality of your website. But for many people, the true power of Joomla! lies in its application framework that makes it possible for thousands of developers around the world to create powerful add-ons and extensions.

This book will guide you through the complexities of implementing add-ons, components, modules, and plugins in Joomla! 1.5. If you feel that you’ve mastered the basics of creating Joomla! extensions, then this book will take you to the next level. Packed with expert advice on all aspects of programming with Joomla!, this book is an invaluable reference guide you will turn to again and again for your Joomla! development tasks.

The book starts by explaining the structure and design of the Joomla! Framework. Then we move on to extending and storing data in standard fields and dealing with multilingual requirements. Further, you will discover best practices, design, and coding methods for Joomla! components, modules, plugins, and other extensions. Along the way, you will actually design and create a component, module, and plugin that work together to add functionality to the Joomla! framework.

You will also learn about customizing the page output using JavaScript effects, making use of Web Services from within Joomla! and ensuring that your code is secure and error-free. You will discover how to easily create sophisticated extensions that are robust, user-friendly, and professional by taking advantage of the many libraries and utilities provided by the Joomla! framework. A comprehensive, up-to-date reference to the Joomla! Framework API is also included in the book.

Finally, we will discuss advanced methods for rendering your extensions more robust, secure, and professional.

The most comprehensive, up-to-date, and accurate developer’s reference for Joomla!

Approach

Packed with expert advice, working examples, and tips, this book is an essential reference guide that you will turn to again and again as you work with Joomla!.

Who this book is for

PHP developers who want to understand how Joomla! Works, with a view to advanced customization or extension development, and who want to learn how to work with the Joomla! Framework.

Code Download and Errata
Packt Anytime, Anywhere
Register Books
Print Upgrades
eBook Downloads
Video Support
Contact Us
Awards Voting Nominations Previous Winners
Judges Open Source CMS Hall Of Fame CMS Most Promising Open Source Project Open Source E-Commerce Applications Open Source JavaScript Library Open Source Graphics Software
Resources
Open Source CMS Hall Of Fame CMS Most Promising Open Source Project Open Source E-Commerce Applications Open Source JavaScript Library Open Source Graphics Software