Zen Cart Logo
Forums / Templates, Stylesheets, Page Layout / Remove Sideboxes from home page

Remove Sideboxes from home page

Locked

Views: 7,496

Results 1 to 20 of 21
This thread is locked. New replies are disabled.
6 Apr 2008, 10:29 PM
#1
tawebworks avatar

tawebworks

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

6 Apr 2008, 11:08 PM
#2
clydejones avatar

clydejones

Deceased

Join Date:
Nov 2005
Location:
Colorado Springs, CO USA
Posts:
7,017
Plugin Contributions:
12

Re: Remove Sideboxes from home page

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.

7 Apr 2008, 12:00 AM
#3
tawebworks avatar

tawebworks

New Zenner

Join Date:
Mar 2008
Posts:
20
Plugin Contributions:
0

Re: Remove Sideboxes from home page

Thank you, oh kind Zen Master!

7 Apr 2008, 12:10 AM
#4
tawebworks avatar

tawebworks

New Zenner

Join Date:
Mar 2008
Posts:
20
Plugin Contributions:
0

Re: Remove Sideboxes from home page

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.

7 Apr 2008, 12:44 AM
#5
clydejones avatar

clydejones

Deceased

Join Date:
Nov 2005
Location:
Colorado Springs, CO USA
Posts:
7,017
Plugin Contributions:
12

Re: Remove Sideboxes from home page

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.

7 Apr 2008, 12:50 AM
#6
tawebworks avatar

tawebworks

New Zenner

Join Date:
Mar 2008
Posts:
20
Plugin Contributions:
0

Re: Remove Sideboxes from home page

Does it need to reside in the same "Common" folder?

7 Apr 2008, 1:21 AM
#7
gjh42 avatar

gjh42

Black Belt

Join Date:
Jul 2005
Location:
Upstate NY
Posts:
21,876
Plugin Contributions:
8

Re: Remove Sideboxes from home page

All css files go in the /includes/templates/your_template/css/ folder.

7 Apr 2008, 1:27 AM
#8
tawebworks avatar

tawebworks

New Zenner

Join Date:
Mar 2008
Posts:
20
Plugin Contributions:
0

Re: Remove Sideboxes from home page

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?

7 Apr 2008, 2:00 AM
#9
gjh42 avatar

gjh42

Black Belt

Join Date:
Jul 2005
Location:
Upstate NY
Posts:
21,876
Plugin Contributions:
8

Re: Remove Sideboxes from home page

It needs to be index_home.css.

7 Apr 2008, 2:08 AM
#10
tawebworks avatar

tawebworks

New Zenner

Join Date:
Mar 2008
Posts:
20
Plugin Contributions:
0

Re: Remove Sideboxes from home page

I made that change.
Still no go.

7 Apr 2008, 2:19 AM
#11
gjh42 avatar

gjh42

Black Belt

Join Date:
Jul 2005
Location:
Upstate NY
Posts:
21,876
Plugin Contributions:
8

Re: Remove Sideboxes from home page

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.
7 Apr 2008, 2:24 AM
#12
barco57 avatar

barco57

Totally Zenned

Join Date:
Apr 2006
Location:
West Salem, IL
Posts:
2,845
Plugin Contributions:
0

Re: Remove Sideboxes from home page

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

7 Apr 2008, 2:27 AM
#13
clydejones avatar

clydejones

Deceased

Join Date:
Nov 2005
Location:
Colorado Springs, CO USA
Posts:
7,017
Plugin Contributions:
12

Re: Remove Sideboxes from home page

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

7 Apr 2008, 2:28 AM
#14
gjh42 avatar

gjh42

Black Belt

Join Date:
Jul 2005
Location:
Upstate NY
Posts:
21,876
Plugin Contributions:
8

Re: Remove Sideboxes from home page

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.

7 Apr 2008, 2:31 AM
#15
barco57 avatar

barco57

Totally Zenned

Join Date:
Apr 2006
Location:
West Salem, IL
Posts:
2,845
Plugin Contributions:
0

Re: Remove Sideboxes from home page

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

7 Apr 2008, 2:37 AM
#16
gjh42 avatar

gjh42

Black Belt

Join Date:
Jul 2005
Location:
Upstate NY
Posts:
21,876
Plugin Contributions:
8

Re: Remove Sideboxes from home page

I know the feeling... :)

7 Apr 2008, 3:17 AM
#17
tawebworks avatar

tawebworks

New Zenner

Join Date:
Mar 2008
Posts:
20
Plugin Contributions:
0

Re: Remove Sideboxes from home page

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"?

7 Apr 2008, 3:24 AM
#18
barco57 avatar

barco57

Totally Zenned

Join Date:
Apr 2006
Location:
West Salem, IL
Posts:
2,845
Plugin Contributions:
0

Re: Remove Sideboxes from home page

click on the link in the post above that says "smart backgrounds", download that mod , unzip it and read the read me. explains everything

7 Apr 2008, 3:32 AM
#19
tawebworks avatar

tawebworks

New Zenner

Join Date:
Mar 2008
Posts:
20
Plugin Contributions:
0

Re: Remove Sideboxes from home page

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!

7 Apr 2008, 7:29 PM
#20
tawebworks avatar

tawebworks

New Zenner

Join Date:
Mar 2008
Posts:
20
Plugin Contributions:
0

Re: Remove Sideboxes from home page

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?