We moved to new unified forum!

Please post all new support queries in our New Forum.

T3 Community Discussion & Support

Let's build the best free Joomla template framework, together!
  1. FuzMic
  2. General Discussion
  3. Wednesday, 11 June 2014
  4.  Subscribe via email
Hi gurus

Just learning T3 in localhost, it is very flexible, i recommend to serious web designers over various i haved tried.

As the title suggest, I am trying to have a background image (../images/pic.jpg) in the header of t3-b3-blank-default template v2.1.4 with t3 framework v2.2.1 set in Non-Development mode so that custom.css is read.

The layout configuration in tpls that is in use has header block as follows:
<div class="t3-wrapper">
<?php $this->loadBlock('header') ?>

In “header” block in \tpls\blocks, the div class is changed to “hdbackground” from “row”
<!-- HEADER -->
<header id="t3-header" class="container t3-header">
<div class="hdbackground">

In ..\css\custom.css the following entry added
.hdbackground {
background: url("../images/pic.jpg";);
width:100%;
margin-left: auto;
margin-right: auto;
}

Unfortunately nothing happens. Chrome>Develop.Tools shows no reference to url(pic.jpg). What did i miss, appreciate help, have been sitting on it for days.
Comment
There are no comments made yet.
Accepted Answer Pending Moderation
0
Votes
Undo
Hi FuzMic,

To add background for header, please do not customize the header.php file. If you did, please convert to default.

Now open your custom.css file then add the following CSS rule:

.t3-header .row {
background: url(../images/t3-banner.png);
}


You can add more style to the rule and change image if you want.

Gardner.
Comment
There are no comments made yet.
  1. more than a month ago
  2. General Discussion
  3. # 1
Accepted Answer Pending Moderation
0
Votes
Undo
G Lunar - Thank you for the pointer which is quick & sweet. Hope to get it fix ASAP and revert. Cheers!!

PS
Following your advice, revert to using original header.block and in custom.css use
.t3-header .row {
background: url(../images/pic.jpg);
}
In Non-development mode, no background image appear in header.

I am sure it is nothing to do with logo.Type setting.
Can it be related to head issue in the configuration default.php relating to lines
[head]
[jdoc:include type="head" ></jdoc:include]
[?php $this->loadBlock('head') ?[
[/head]

Someone suggested the following in header.block the extra line [div class="container"] as follows:
[header id="t3-header" class="t3-header"]
[div class="container"]
[div class="row"[ [/div]

PLUS in template.css, the following
.t3-header {
padding-top: 0px;
padding-bottom: 0px;
background: red;
}
#t3-header .container {
background: url(../images/pic.jpg);
}

What say you on this? How to make yours work, I prefer a simple/sweet change in custom.css? Please help guru. :(
Comment
There are no comments made yet.
  1. more than a month ago
  2. General Discussion
  3. # 2
Accepted Answer Pending Moderation
0
Votes
Undo
Adding style to custom.css file is the simplest way and safe also. When you customize a file, it can affect other places in your site, so you have to make sure the customization works properly in all cases.

Gardner.
Comment
There are no comments made yet.
  1. more than a month ago
  2. General Discussion
  3. # 3
Accepted Answer Pending Moderation
0
Votes
Undo
Gardner thank you again for the watch. I found the reason why! I place the pic.jpg in the wrong folder, it should be in the template\images folder because of the "...\images"; NOT the root\images folder. In short your advice is correct and fully agreed. Sorry for the fuzz.
Comment
There are no comments made yet.
  1. more than a month ago
  2. General Discussion
  3. # 4
Accepted Answer Pending Moderation
0
Votes
Undo
I do a lot of background customizing. I always use background-color: blue; (or whatever ) rule to check if I have selectors and custom.css set up properly before i use url's. Relative and absolute url's can be tricky. You can also view page source to check custom.css is loaded by clicking on it. As far as I can tell, custom.css is loaded in both dev and non-dev mode it is not related to less and is not overridden in upgrades.
Hope this helps.
Comment
There are no comments made yet.
  1. more than a month ago
  2. General Discussion
  3. # 5
Accepted Answer Pending Moderation
0
Votes
Undo
Hi FuzMic,

I also forgot to note you about the image path :). Glad to see you figure out that.

@DavidMc: it's absolutely right.

Gardner.
Comment
There are no comments made yet.
  1. more than a month ago
  2. General Discussion
  3. # 6
Accepted Answer Pending Moderation
0
Votes
Undo
David i tinker that out too abt Custom.css being read irrespective of dev or non mode. By the way i found the culprit to the path by using Chrome.Dev-Tools as you have indicated.

Now i want to use custom.css extensively, guys where can i read more & leap frog, any suggestion. Cheers!
Comment
There are no comments made yet.
  1. more than a month ago
  2. General Discussion
  3. # 7
  • Page :
  • 1


There are no replies made for this post yet.
However, you are not allowed to reply to this post.