Viewers: in countries Watching now:
Joomla! 1.5: Styling with CSS shows how those familiar with Joomla! and with hand-coded HTML and CSS can take the next step in creating a dynamic website with a unique look and feel. Jen Kramer McKibben goes deep into the functionality of this open-source content management system, exploring topics like putting more style into modules, editing CSS on the fly using the Firefox Web Developer toolbar, creating horizontal and vertical menu layouts, and including images in those menus. Exercise files accompany the course.
Now that we have got our homepage looking great, I am going to style the Login Box to make it match the nice look that we have going on, on the right side of this page. This is the default styling for the login box and the little border that you see going around the Username and the Password is from the Field Set tag, if you haven't encountered that particular HTML tag before. We have two links at the bottom. You may have three depending on how you have your Joomla! configured. I have my Joomla! configured to not allow registrations on the website.
If you have registration on the website enabled, you may have an extra bullet at the bottom that says to sign up for an account essentially. So let's go ahead and get started with styling this login box. So we are going to go to CSS > Edit CSS. And I am going to go to the default.css page and I am going to scroll down to the right area of our style sheet. Well, you have a lot of styling in here for the featured products area and now we are going to add styles here for the login.
So I am going to start by styling the outside box, which of course is always a div.module table. I am going to set a width on this around 220 pixels which will make it a little bit narrower, and a smaller font size because we want to deemphasize this login box relative to other things on this page. I am also going to set a background color, which will set off the box just a little bit from the rest of the page itself. Now, we have our words and our boxes running up right against the edge of that colored box.
So I am going to need to add some padding. Let's also push the box over, so that it lines up nicely with the Our featured products on top. Right now it's skewed a little bit to the left. We can do that with margin, and finally let's separate that login box from the Our featured products. We will give a little margin on the top. Now I am going to style my H3, and actually I want my H3 for the login to look pretty similar to the H3 that I have for Our featured products. But I'd really don't want that left styling. In Our featured products, we have a big set of padding on the left side that's associated with H3, and we have a dark color as well.
So I am going to setup my H3 for the login box as a separate style. So right div.moduletable h3. Let's give it a color of white and the Georgia font that we have been using, which is font family, Georgia and Serif. Once again, we want it more of a normal weight. So a font weight of normal, which will make it less bold, and a size of 14 pixels. Now, let's get rid of that ugly field set border that you see around the Username and Password.
So once again, right div.moduletable field set, and we will just set the border here to None. Now, I would like to style this login box down here to match other buttons that we have had on the website. I am going to make it brown. So right div.moduletable input.button. Generally speaking, all of the buttons on a Joomla! website have the same class of button. Let's set the text color to white, which is fff, and we will set our background color to Chocolate Brown, 463 11c. And finally, we will set the border around that button to None.
Now finally, these last two links on the bottom here for Forgot your Password or Forgot your Username, they are kind of far apart and I would like to do a little bit more with the alignment with them. So let's work on styling the list that's in this login box. So right div.moduletable ul, we want to list style type of None to get rid of the bullets. Then we are going to put some padding just on the left side, 0 0 0 and 5 pixels.
This gets rid of some of the residual padding that we have had associated with this before based on other styling further up in the style sheet. And finally, let's set the margin to 0. That will help with some other web browsers. Finally, I would like to put just a little bit of padding around those individual links. But again, I am going to override what I have earlier for the LI tag for some of the spacing between list items. So this will be right div.moduletable li.
This time, we are going to set our padding to 0.3 ems and that will tighten things up nicely. Now, we have a nice clean line going down the left side from Username down to Forgot your Username. So as our last step, we need to copy all of our CSS and put it into our Joomla! template. So Ctrl or Command+A, Ctrl or Command+C to copy all of our code. Then we will switch to the back end of the website to Extensions > Template Manager, to Inside, Edit, Edit CSS, Default, Edit and now, we are going to say Ctrl or Command+A, Ctrl or Command+ V to paste in our changes and save.
Now, let's Refresh the homepage, and you will see that all of our changes have been incorporated into the website. So login box is very handy for hiding some content away for just registered users, which I will show you how that works in the next video.
Find answers to the most frequently asked questions about Joomla! 1.5: Styling with CSS .
Here are the FAQs that matched your search "" :
Sorry, there are no matches for your search "" —to search again, type in another word or phrase and click search.
Access exercise files from a button right under the course name.
Search within course videos and transcripts, and jump right to the results.
Remove icons showing you already watched videos if you want to start over.
Make the video wide, narrow, full-screen, or pop the player out of the page into its own window.