Zen Cart Logo
Forums / Basic Configuration / Sidebox in header, almost there. Need div id

Sidebox in header, almost there. Need div id

Locked

Views: 1,661

Results 1 to 5 of 5
This thread is locked. New replies are disabled.
7 Jul 2007, 8:20 AM
#1
shocker avatar

shocker

Zen Follower

Join Date:
Jul 2007
Location:
Jakarta
Posts:
346
Plugin Contributions:
0

Sidebox in header, almost there. Need div id

Regarding placing side boxes in the header, I think I'm on the right track. (I couldn't find a mod in the download section.) I have fond the place in the tpl_header.php where the search_header.php is specified, so no problem right just stick the other in divs before or after it. I got that far but what are the div ids?

so far I have simply copied, modified side box names and pasted them above the search_header.php div like this:

<div id="navMainSearch"><?php require(DIR_WS_MODULES . 'sideboxes/language.php'); ?></div>
<div id="navMainSearch"><?php require(DIR_WS_MODULES . 'sideboxes/currencies.php'); ?></div>
<div id="navMainSearch"><?php require(DIR_WS_MODULES . 'sideboxes/search_header.php'); ?></div>

I have done a search on to see if I could find these other side boxes defined someplace to just use the div id from them, but to no avail.

thanks

shocker

7 Jul 2007, 9:03 PM
#2
kobra avatar

kobra

Black Belt

Join Date:
Aug 2005
Location:
Arizona
Posts:
31,500
Plugin Contributions:
4

Re: Sidebox in header, almost there. Need div id

Get FireFox and the web developers tools to assist you in determining what is what.

The 2 that you listed are
#languages
#currencies

14 Jul 2007, 4:14 AM
#3
shocker avatar

shocker

Zen Follower

Join Date:
Jul 2007
Location:
Jakarta
Posts:
346
Plugin Contributions:
0

Re: Sidebox in header, almost there. Need div id

I do use the FF Web Developer tools. Who would developed without it.?

But my problem is not where the code goes, but what code goes in the place where I want the boxes to appears.

I created to new divs next to the search but what code goes in those divs to display the currency and language boxes?

I'm trying do do thing very neatly and carefully since I'm new to ZenCart. I mean I could hack at it and get it working. I guess I'm trying do this elegantly in the same light as ZenCart.

thanks kobra

14 Jul 2007, 4:24 AM
#4
gjh42 avatar

gjh42

Black Belt

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

Re: Sidebox in header, almost there. Need div id

You wouldn't want to use the id's of the sideboxes from their original locations.

Just make new id's that mean something, like headerLanguage and headerCurrencies, and add those to your stylesheet and style them.

#headerLanguage {
aaaaa: bbbbb;
}
#headerCurrencies {
ccccc: dddddd;
}

14 Jul 2007, 4:47 AM
#5
shocker avatar

shocker

Zen Follower

Join Date:
Jul 2007
Location:
Jakarta
Posts:
346
Plugin Contributions:
0

Re: Sidebox in header, almost there. Need div id

Ok, I fugured that, but what is the piece of code to display the boxes. This...

<?php require(DIR_WS_MODULES . 'sideboxes/language.php'); ?>
<?php require(DIR_WS_MODULES . 'sideboxes/currencies.php'); ?>

didn't work.

thanks again. I'm probably thinking that this is more difficult than it actually is:blush:.

thanks gjh42

s.ali