Zen Cart Logo
Forums / Other Business Topics / Sidebox Overrides

Sidebox Overrides

Sticky Locked

Views: 15,637

Results 21 to 40 of 41
This thread is locked. New replies are disabled.
17 Jan 2006, 5:13 PM
#21
asorethumb avatar

asorethumb

New Zenner

Join Date:
Jul 2005
Posts:
76
Plugin Contributions:
0

Sidebox Overrides

Hi!

I am only using sideboxes on one page; my wordpress blog page.
(main_page=wordpress)

I have tried following this thread,and here is the code I have added to my wp_archives and wp_cats pages:

$show_(my sidebox) = false;
if ($GET[ 'main_page' ] == 'wordpress'){
$show
(my sidebox) = true;
}

Im getting a T-string error. Can anyone advise?

tia.

17 Jan 2006, 8:21 PM
#22
asorethumb avatar

asorethumb

New Zenner

Join Date:
Jul 2005
Posts:
76
Plugin Contributions:
0

Re: Sidebox Overrides

heres the entire code for the wp_archives:

require($template->get_template_dir('tpl_wp_archives.php',DIR_WS_TEMPLATE, $current_page_base,'sideboxes').

'/tpl_wp_archives.php');

$title = BOX_HEADING_WP_ARCHIVES;
$left_corner = false;
$right_corner = false;
$right_arrow = false;
$title_link = false;

$show_(my sidebox) = false;
if ($GET[ 'main_page' ] == 'wordpress'){
$show
(my sidebox) = true;
}

require($template->get_template_dir($column_box_default, DIR_WS_TEMPLATE, $current_page_base,'common') . '/' .

$column_box_default);
?>

17 Jan 2006, 11:14 PM
#23
dwno avatar

dwno

Totally Zenned

Join Date:
Jan 2005
Posts:
1,285
Plugin Contributions:
0

Re: Sidebox Overrides

You're supposed to replace (my sidebox) with whatever the name of your sidebox. ;)

18 Jan 2006, 3:51 PM
#24
asorethumb avatar

asorethumb

New Zenner

Join Date:
Jul 2005
Posts:
76
Plugin Contributions:
0

Re: Sidebox Overrides

dwno:

You're supposed to replace (my sidebox) with whatever the name of your sidebox. ;)
ha. thank you.
ya know, that went through my mind for a second, and then as quick as it came it was gone.

so, the sidebox name? how do i find that exactly?
wp_archives isnt working.
archives isnt working.
archives_box isnt working.

sorry if this is a dense question, and thank you to anyone who can help!

18 Jan 2006, 4:36 PM
#25
dwno avatar

dwno

Totally Zenned

Join Date:
Jan 2005
Posts:
1,285
Plugin Contributions:
0

Re: Sidebox Overrides

What exactly are you trying to do..
-hide all sideboxes from all pages except your blog page?
-hide your blog sidebox from all pages except your blog page?
-other?

18 Jan 2006, 4:40 PM
#26
asorethumb avatar

asorethumb

New Zenner

Join Date:
Jul 2005
Posts:
76
Plugin Contributions:
0

Re: Sidebox Overrides

dwno:

What exactly are you trying to do..
-hide all sideboxes from all pages except your blog page?

-other?
-hide my blog sideboxes from all pages except my blog page

18 Jan 2006, 5:42 PM
#27
dwno avatar

dwno

Totally Zenned

Join Date:
Jan 2005
Posts:
1,285
Plugin Contributions:
0

Re: Sidebox Overrides

In your sidebox file, add this to the beginning, after the <?php and license info if present:

 $show_blog = false;
 if ($_GET['main_page'] == 'wordpress') {
  $show_blog = true;
 }
 if ($show_blog === true) {

and at the end of the file, add this before ?>

}

I haven't looked at that addon, but I think that should work.

18 Jan 2006, 6:04 PM
#28
asorethumb avatar

asorethumb

New Zenner

Join Date:
Jul 2005
Posts:
76
Plugin Contributions:
0

Re: Sidebox Overrides

worked perfectly. thank you!

21 Jan 2006, 7:45 AM
#29
bettysue avatar

bettysue

Inactive

Join Date:
May 2004
Posts:
747
Plugin Contributions:
0

Re: Sidebox Overrides

Two different sidebox questions:

On the categories sidebox, how do you keep it from centering the category listing? I want the main categories to align left.

Secondly, on the Specials sidebox, how do I change the link text for Specials to a different color other than the default A links color? The problem is that the class file is given before the <a href= which means the text link won't pick it up and just use whatever is the default.

I just can't figure out in the specials template where in the line of code to put the font color or a class link.

Thank You,

b

23 Jan 2006, 11:06 PM
#30
bettysue avatar

bettysue

Inactive

Join Date:
May 2004
Posts:
747
Plugin Contributions:
0

Re: Sidebox Overrides

I fumbled for a while but fixed both of these issues I had questions about:

On the categories sidebox, how do you keep it from centering the category listing? I want the main categories to align left.

I added a new style to the stylesheets (boxText2) which I included a text-align: left in it. I changed the class name in the tpl_box_default_left.php only since I am not using any boxes on the right.

[quote][b]Secondly, on the Specials sidebox, how do I change the link text for Specials to a different color other than the default A links color? The problem is that the class file is given before the ' . $title . BOX_HEADING_LINKS . '';

to: $title = '' . '<font color="#ffffff">' . $title . BOX_HEADING_LINKS . '';

b

26 Jan 2006, 4:31 AM
#31
tomcoh avatar

tomcoh

New Zenner

Join Date:
Feb 2005
Posts:
5
Plugin Contributions:
0

Re: Sidebox Overrides

I just got this code to work perfectly for the homepage:

 $show_manufacturers_list = false;
 if ($_GET['main_page'] == 'index') {
  $show_manufacturers_list = true;
 }
 if ($show_manufacturers_list === true) {

thanks to those who contributed that earlier.

the only issue now is that I need it only to render on the home screen and no other index screens. Anyone have any tips?

thank you in advance. :)

27 Jan 2006, 1:02 AM
#32
patj avatar

patj

New Zenner

Join Date:
Dec 2004
Posts:
53
Plugin Contributions:
0

Re: Sidebox Overrides

A different sidebox question..

How does the single column work. I want one column on the left, none on the right, but also want the main middle section spread out to fill up the right side.

In admin, if I turn off the left/right feature, and turn on the single column feature, the disappears.

Cheers, :huh:

27 Jan 2006, 1:27 AM
#33
Kim avatar

Kim

Obaa-san

Join Date:
Jun 2003
Location:
West Coast, North America
Posts:
26,607
Plugin Contributions:
0

Re: Sidebox Overrides

Ignore the single column option. If you only want one column, simply turn one off in Admin> Configuration> Layout settings.

27 Jan 2006, 2:01 AM
#34
patj avatar

patj

New Zenner

Join Date:
Dec 2004
Posts:
53
Plugin Contributions:
0

Re: Sidebox Overrides

Thanks Kim
You guys rock!! ::tup

31 Jan 2006, 4:42 AM
#35
tomcoh avatar

tomcoh

New Zenner

Join Date:
Feb 2005
Posts:
5
Plugin Contributions:
0

Re: Sidebox Overrides

ignore my question. found it on the first page of this thread

if ($_GET['main_page'] == 'index' and $current_category_id=='')

thanks ajeh

31 Jan 2006, 4:50 AM
#36
ajeh avatar

ajeh

Oba-san

Join Date:
Sep 2003
Location:
Ohio
Posts:
62,757
Plugin Contributions:
1

Re: Sidebox Overrides

You are most welcome ... there are lots of groovy ways to customize a sidebox ...

All it takes is knowing what's more true ... B)

31 Jan 2006, 8:05 PM
#37
bettysue avatar

bettysue

Inactive

Join Date:
May 2004
Posts:
747
Plugin Contributions:
0

Re: Sidebox Overrides

**there are lots of groovy ways to customize a sidebox **

I hope this is the case in what I am trying to do :)

I need the Specials side box only to be longer. This is because the person that I'm building the store for wants to use a large price font and now everything is all squished together and barely legible.

So I need to add some
's in there or something. I have tried adding them all over the tpl_specials.php file and they are not being acknowledged. More than likely due to the fact I am either incorrectly placing them in the code (although I get no error messages), or placing them in the wrong places.

Help appreciated :blink:

b

4 Feb 2006, 11:22 PM
#38
the_divide avatar

the_divide

New Zenner

Join Date:
Feb 2006
Posts:
3
Plugin Contributions:
0

Re: Sidebox Overrides

I don’t know why but I cant get the side boxes to override. Basically I have a music genre sidebox on the left hand side and I want to get it to disappear when I’m on the information pages. The problem is when I add the code nothing happens…

Edited catalog/includes/modules/sideboxes/xxxxx(site name)/music_genres.php

if ($_GET['main_page'] == 'privacy'){
 $show_music_genres= false;
} else {
 $show_music_genres= true;
}

http://www.forbiddensilence.co.uk/zencart/...main_page=index

As far as i know im in the right php file. Do I have to add IF statements to every single sidebox file for it to take effect? I must be doing something wrong

:lol:

Dan

5 Apr 2006, 2:56 AM
#39
sonam avatar

sonam

New Zenner

Join Date:
Apr 2006
Location:
New York City
Posts:
2
Plugin Contributions:
0

Re: Sidebox Overrides

I am trying to delete a number of things :

"Sales Message Goes Here"
Sponsors
New Products
Have You Seen

I simply cannot do it. Suggestions anyone ?

Thanks very much.

http://billtoole.net/ZenCart/index.php

5 Apr 2006, 3:04 AM
#40
ajeh avatar

ajeh

Oba-san

Join Date:
Sep 2003
Location:
Ohio
Posts:
62,757
Plugin Contributions:
1

Re: Sidebox Overrides

Peek in the Admin ... Tools ... Developer's Tool Kit ...

Bottom input box type what you are looking for ... select Catalog ... click Search ...

It will show you where the default defines are that you can then use for your overrides ...