How To Edit Joomla Templates - Part 2

Posted by: webmaster in TutorialTemplatesJoomla 1.5 on  

In part 1 of this article, it was explained how to edit a Joomla Template. It was the theoretical explanation and if you're new to Joomla, it might be a bit abstract. In this second part, I demonstrate this with a practical example, as looking at an example is often the best way to learn something. Once you have done this a few times, you will be able to change a template to your needs within a couple of minutes.

 

Let's start with picking a template. For this article, I took the October Template of Ulti Joomla.

Edit Joomla Templates

Suppose I want to use this template for a site about my golf club. The first thing I will do, is change some images. I want to put some golf elements in the template, like the logo of the golf club and a picture about golf. In the figure below, you can see where I want to put these.

Edit Joomla Templates

I just open the zip-file of the downloaded template. I take a look at the folder called 'images' and there I find the two images I want to replace. I just have to replace these images with my golf images. Before I did this, I first resized my golf images to the same size as the original images and renamed them to the same name. Now I just create a new zip-file and install this template. This looks already more like a golf template.

Edit Joomla Templates

Now I want to do something about the colors. The colors of my golf club are green and blue, so let's put some blue in it. In the backend of my site, I go to the Template Manager, choose to edit the just installed template and then I edit the css-file. Now I want the background outside the content borders to be blue. Looking at the images that are used to show the current background, it's easy to see that I have to replace bodybg.jpg and wrapbg.jpg.

Edit Joomla Templates

I will not replace these images with another background image, but just with the color #3333BB;

Edit Joomla Templates

I will change the color of the headers also. Looking in the css-file, I easily find back the color of the headers.

Edit Joomla Templates

So I replace this also with the same blue color #3333BB. Note that if you don't understand the code above, you should learn the css-basics first. There's a link to a great tutorial in the first part of this article.

 

Finally I will put the column on the right, on the left side. This requires a closer look in the code. But once you know a bit of html and css, you'll find it easy to discover where the place of the first and second column is located in the css-file.

Edit Joomla Templates

I swap these two, just by changing the float:left to float:right and vica versa.

 

Here's my final result:

Edit Joomla Templates

If you compare this with the original template, you'll see that just a few changes can change the look of your template a lot. If you've never done this before, it will require some practice before you get the hang of it. If you want to become more familiar with this, I would advice you to install somewhere a testsite, and just experiment and have some fun with it!

 

 

Trackback(0)
Comments (27)Add Comment
What about adding a picture to a template?

written by Stefan, February 27, 2009
Thanks for a good expanation.
What do I do if I want to add images to a template, not just replace them?
And also if I want to use Flash images, is that a diffrent process?
best regards
Stefan
What about creating a space for a footer?

written by cory, March 05, 2009
Thanks for the tutorial! This article has pointed me in the right direction on css editing. Was wondering though if one could create a space for a footer where originally there was not one.
How to change the menu javascrip

written by Hemal Shah, May 07, 2009
I want to add a drop down javascript menu for my joomla template. how can I do that?
drop down menu

written by Largowww, May 08, 2009
The easiest way to do that, is to add an extension for this. Have a look at the Suckerfish menu or the SW Menu maker.
Thanks!

written by Dave L, May 18, 2009
Thanks for writing this tutorial, helped alleviate a lot of frustration!smilies/smiley.gif
...

written by tinboon, May 21, 2009
And maybe change the name of the show to “Mozart Gamer Show” http://rapid4me.com/?q=Mozart+Gamer+Show . I think you might consider wearing a tie too.

Vivica Fox might be available too, she hasn’t done much lately.
...

written by David, May 25, 2009
Ok, i just put a new template for my site, ticketairwaves.com If you look at the site the left modules is moved a little to much to the rite and there is a lot of empty space to the left of it...as is the same for the right modules.....because of this its also cutting my article off a little bit. So how would i move the left module more off to the left, and the right modules more over to the right. again the site is ticketairwaves.com
...

written by Largowww, May 28, 2009
I'm not sure what you mean exactly as your site looks quit ok to me. Anyhow, if you have specific questions about a template, you should ask the guys who made the template. If you know a bit of css, you can find it yourself. But as every template is different, there is no answer out of the box.
How change stylesheet url of a template?

written by Menno, May 28, 2009
How do i change the stylesheet url of a template between the tags? smilies/shocked.gif

For example:
...

written by Menno, May 28, 2009
link rel="stylesheet" rel="nofollow" href="/templates/
...

written by Largowww, May 28, 2009
The commenting system messes up the code you type. So it's not really clear to me what you're asking. It's better to use our forum for these type of questions.
...

written by albatr0s, June 06, 2009
Hi, thanks for the explanation. I have two more questions. :-)
I normally use expression web 2 for static pages.
- I want to convert my site to a dynamic one, possibly by using joomla. My first question is: how can do that?
- can I use expression web 2 for eidting joomla templates? Maybe, should have I to put html and css codes generated by Expression web somewhere into joomla?
Thanks a lot
Alberto

...

written by Largowww, June 06, 2009
I've never used expression web 2, so there is not much I can say about it. I would advice you to go to the official joomla site and look for the template tutorial there. Once you know how a Joomla template works, you'll probably find how you can transform your static pages to a template.
Thank you

written by kimsamsoonni, June 25, 2009
Thank you for the best how to.smilies/grin.gif
Adding 'Register Online ' page

written by Sushma, June 26, 2009
How do I add a "Register Online" page to it?I mean connecting the database to the login page?
...

written by Largowww, June 26, 2009
You should do this by adding a menu item pointing to the login component. But this has nothing to do with editing a template. You should ask these kind of questions on forum.joomla.org
...

written by Lydia, August 20, 2009
Hi

this might be a bit more complicated but what would i be looking for if i want the template to change the header image (background image) when i click on different menus or if i want a simple picture slideshow?
Just point me in the right direction and i will go read how to do it.
...

written by Lydia, August 20, 2009
actually what i am asking is how i would change the css code to load a simple slideshow of the header image
...

written by Largowww, August 26, 2009
To do that, I would install one of the many existing slideshow extensions and add a module position to the header if needed.
...

written by Dadaso Mahadev chavan, October 27, 2009
thanks for the details explanation.
...

written by Software development india, February 16, 2010
Thanks for providing practical example which can be easily implement.
Editing Site Name

written by Murray, February 23, 2010
Great tutorial!.

My question: The site name on my template is on top of the 960x237 graphic "headerimg.jpg". I am new to this, but from what I can see the Site Name is called up by:
(this is in index.php)

To change the font, make the site name italic, and also larger, I have edited the code to read:


The font changes and goes into italic, but it doesn't get any bigger.

I would also like to use a more fancy font but the CSS just has Tahoma, Verdana, Arial and Sans Serif. Can I still use any font? Or am I better to grab the main graphic, put fancy stuff on top of it using GNU or whatever and save it all as a jpg? (then to save it back into the template graphic).

Phew? I've spent some hours on this!
@murray

written by Largo, February 23, 2010
Of course you can use anything you like and use any font you like. You should change the css of your template. Just go to the template manager, edit the css-file and look there where the font is defined.
...

written by Murray, February 23, 2010
In note above, the programing did not publish. Hope Ive got it this time


My question: The site name on my template is on top of the 960x237 graphic "headerimg.jpg". I am new to this, but from what I can see the Site Name is called up bysmilies/sad.gifthis is in index.php)



To change the font, make the site name italic, and also larger, I have edited the code to read:


The font changes and goes into italic, but it doesn't get any bigger.

I would also like to use a more fancy font but the CSS just has Tahoma, Verdana, Arial and Sans Serif. Can I still use any font? Or am I better to grab the main graphic, put fancy stuff on top of it using GNU or whatever and save it all as a jpg? (then to save it back into the template graphic).

Phew? I've spent some hours on this!


...

written by Largo, February 24, 2010
@Murray:

you can't put code in the comment. The comment extension sees that as html and throws it away. You can use our forum or contact page to send your question to us, although I would advice you to go to the official Joomla forum with this kind of question.
...

written by Abishek, July 01, 2010
Hi,

I have been trying to have 4 separate articles in one row. How do i do this? Any help would be appreciated!
Editing modules etc?

written by Mr Twister, October 11, 2011
Hello and thank you for the tutorial. I understand from this how to change simple CSS stuff, since I already know some css, but what do I do if I want to add / remove modules, or place them in different positions etc?

Thank you

Write comment

security code
Write the displayed characters


busy