Before you start working with Joomla 2.5, you need to install on the server a fresh version containing demo data, from which you need to delete unnecessary items. The example of the theme for creating a version of Joomla 2.5 will consider the question of how to make a template for Joomla. First you need to install the previously created archive in Joomla. To do this, you must use the Template Manager, which includes your own default template.

  • After the trial data has been deleted,you must include the resulting template in the admin panel. Then go to the site where you can see the white sheet. This is because there is no work code in the new template.
  • Calculate the future structure of the template. For example, the structure will consist of a header, top menu (navigation), content, right column and basement.
  • Create a site layout. To edit open the index.php file, connect the Joomla head meta tags output function first. Write the html-tags of the framework, and enter the data into the block.
  • Connect the head meta tags of Joomla. Connect the standard output of the data. Go to the css folder, delete all the contents and create your own file named template.css, where the styles of your template will be written. After that, open up index.php again and connect your css.
  • Connect the stylesheet by definingpath to the folder with the template. Element php insertion echo $ this-> baseurl - displays the url of the site, and the insertion $ this-> template represents the path to the template folder. After entering the parameters, you must go to the site and check if the css file is correctly connected. Now-make the html markup of the template. To create styles and structure of a site it is possible at once, looking through what kind the site has.
  • When the main blocks of the page were mapped,It is necessary to make sure that the template looks correct and does not fall apart. After that, you can add module positions. Example: The top navigation menu is added. The position is called topmenu. Go to the templateDetails.xml file, then add it to the block topmenu (the position can be any name convenient to you).
  • Next, to make a template for Joomla 2.5 is necessary by adding to the templateDetails.xml file the module position as topmenu. Now you should save and go back to the index.php file, where you can bind the output of this position to the location you need. To do this, use the following line:
    <jdoc: include type = "modules" name = "topmenu" />
  • The module is output in the right place. The name of the item in the templateDetails.xml file is used as the name parameter. Accordingly, now, the #topmenu block displays the position of the topmenu module. To view module positions in the browser, you must enable this function in the admin panel. Go to the template manager, open options and specify "display template fields".
  • Now if you go to the site and enter into the addressthe line is the following: http: // site address /? tp = 1, then you can see which fields are in the template. To bring the menu to the topmenu position, go to the module manager, select the menu module, publish to the topmenu position, specify "display on all pages" and browse. The site should have a menu.
  • Now make out the menu to your liking through template.css. When it is ready, you can display the content of the page using the line:
    <jdoc: include type = "component" />.

Now you can start creating styles for articles,links and other things. More to read about some important and tricky moments, as well as how to download, prepare or make a template joomla you can on the pages here and here.

Comments 0