-
Book Overview & Buying
-
Table Of Contents
Learning Joomla! 3 Extension Development - Third Edition
By :
Now we are going to create another view that is dedicated to each individual item, and will show a larger image. We will make this view appear when you click on the title of an item. This view will be important when we integrate comments in our extension later in this chapter.
Create the folio.php file under /components/com_folio/controllers/ and add the following code:
<?php
defined('_JEXEC') or die;
class FolioControllerFolio extends JControllerForm
{
}This code is similar to our controller for our folios view where all of the functionality is inherited from the parent class.
Now, create the model file at /components/com_folio/models/folio.php, and add the following code. This code is pretty much the same as the folios model; however, we are using id instead of catid to select the item. The differences are highlighted as follows:
<?php
defined('_JEXEC') or die;
class FolioModelFolio extends JModelList
{
public function __construct($config = array())
{
...
Change the font size
Change margin width
Change background colour