New Zenner
- Join Date:
- Mar 2008
- Posts:
- 20
- Plugin Contributions:
- 0
Remove Sideboxes from home page
I know I'm missing something... but where can I "turn off" side boxes for just my home page?
http://www.souvenirsofhiltonhead.com
Views: 7,496
New Zenner
I know I'm missing something... but where can I "turn off" side boxes for just my home page?
http://www.souvenirsofhiltonhead.com
Deceased
tawebworks:
I know I'm missing something... but where can I "turn off" side boxes for just my home page?
http://www.souvenirsofhiltonhead.com
open includes/templates/YOUR_TEMPLATE/common/tpl_main_page_php.
at around line 45 add the following code:
if ($this_is_home_page) {
$flag_disable_right = true;
$flag_disable_left = true;
}
save the file and upload to your server.
New Zenner
Thank you, oh kind Zen Master!
New Zenner
Is there an addition I can make to the code you noted to display a different header image?
I would also like to link the home page header to the shopping cart.
Deceased
tawebworks:
Is there an addition I can make to the code you noted to display a different header image?
I would also like to link the home page header to the shopping cart.
That code just turns off the sideboxes on the main page.
to change the header you could create an additional css file called index_home.css
that would handle the header on the main page.
New Zenner
Does it need to reside in the same "Common" folder?
Black Belt
All css files go in the /includes/templates/your_template/css/ folder.
New Zenner
Here is the code of my file (includes/templates/southart/css/index-home.css):
#logoWrapper{
background-image:url(../images/logo-shop.gif)
background-repeat:no-repeat;
background-color: #ffffff;
height:96;
}
Yet, this is not working.
What am I doing wrong here?
Black Belt
It needs to be index_home.css.
New Zenner
I made that change.
Still no go.
Black Belt
This may not affect the image choice, but you are missing the height units specification:
#logoWrapper{
background-image:url(../images/logo-shop.gif);
background-repeat:no-repeat;
background-color: #ffffff;
height:96;
}
```should be height:96px;
This does make a difference when added to your index_home.css, so the file is being read.
How is logo-home.gif different from logo.gif?
You are trying to change the logo with the css background-image property, but the logo is a foreground image called directly in the code. It will not work the way you are trying it.
Totally Zenned
Its not changing because you are still calling the logo from the define, which is the same as hard coding it. You need to remove the define for the logo and only call it through the stylesheet. your gonna ask me which file the define is in ........let me go look
Deceased
barco57:
Its not changing because you are still calling the logo from the define, which is the same as hard coding it. You need to remove the define for the logo and only call it through the stylesheet. your gonna ask me which file the define is in ........let me go look
its in includes/languages/english/YOUR_TEMPLATE/header.php
Black Belt
You can either change the logo to be a background image so css can affect it, or add code to switch logo images depending on page.
Smart Backgrounds has a variant described in its readme for switching foreground images.
Totally Zenned
you beat me to it......I was just about to paste.....
you'll have to manage the logo now from the main stylesheet and the index_home.css as background image.....or you could write an if/else to check if your on the home page and then not call the image from the define.....else display as normal for all other pages.....isn't there some code floating around here to do just that....
looks like my posts are about 30 seconds behind everyone else LOL
Black Belt
I know the feeling... :)
New Zenner
I LOVE you guys!
OK... so what's the best way for me to do this.
Anyone find the "code floating around to do this"?
Totally Zenned
click on the link in the post above that says "smart backgrounds", download that mod , unzip it and read the read me. explains everything
New Zenner
You guys are ENTIRELY too kind... and I sincerely THANK YOU!
Now, it's 11:30 my time and I'm hitting the sack. But please rest assured I'll crank up first thing tomorrow morning with this... and report back.
Bless you all, kind masters!
New Zenner
OK, guys...
I've downloaded the Smart Backgrounds Mod, but can't decipher where I designate a particular background for a particular page. It seems to me it's in the CSS, but the sample stylesheet declarations did not tell me enough.
What am I missing here?
Tell staff why this post should be reviewed.