Forums / Templates, Stylesheets, Page Layout / Center Align Category/Sub-Category Images?

Center Align Category/Sub-Category Images?

Views: 6,390

Results 1 to 17 of 17
2 Oct 2007, 3:08 AM
#1
lmw1 avatar

lmw1

Zen Follower

Join Date:
Mar 2007
Posts:
105
Plugin Contributions:
0

Center Align Category/Sub-Category Images?

When I click on a category or sub-category, everythings aligned left stacked on top of each other. I want it to be 'center-aligned'.

Any ideas?

Thanks in advance!
LMW1

2 Oct 2007, 6:31 AM
#2
kobra avatar

kobra

Black Belt

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

Re: Center Align Category/Sub-Category Images?

Post a link directly to the page in question

Zen-Venom Get Bitten

2 Oct 2007, 8:05 AM
#3
lmw1 avatar

lmw1

Zen Follower

Join Date:
Mar 2007
Posts:
105
Plugin Contributions:
0

Re: Center Align Category/Sub-Category Images?

I'm building the site offline. here's an image for a visual of my questions.

Thanks for your help & knowledge.

LMW1

2 Oct 2007, 8:38 AM
#4
gjh42 avatar

gjh42

Black Belt

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

Re: Center Align Category/Sub-Category Images?

  1. The image is not clear enough to tell whether you have the categories-tabs menu or the ez-pages menu displayed there.
    If it is ez-pages, you can create two new pages which are internal links pointing to your link destinations, and enable them in the header menu.
    If it is cat-tabs, you can copy the code from the "navigation display" section to the cat-tabs section in tpl_header.php. (It may actually be a bit more complicated than that.)

  2. Get the Firefox Web Developer extension, and use the Information > Display Element Information button to find the class applied to the subcat elements. If the stylesheet has that class marked as "float: left;", delete that, and add "text-align: center;" or "margin: auto;". It's tricky diagnosing from a picture; experiment!

  3. Again, it's hard to be sure what it is you want from the picture. Is "Body Jewelry" a top category? If so, are you saying you don't want top cats selectable in the sidebar? Or that you don't want any cats selectable in the sidebar? The categories box can be manipulated in many ways, but I need some more detail before I can offer useful advice.

2 Oct 2007, 9:12 AM
#5
lmw1 avatar

lmw1

Zen Follower

Join Date:
Mar 2007
Posts:
105
Plugin Contributions:
0

Re: Center Align Category/Sub-Category Images?

Thanks for the quick reply! I greatly appreciate it!

  1. The top bar is not ez-pages. Its cat tabs. How can I put 'Home' on the far left side, and 'Contact Us' on the far right side?

  2. I will try to find the right place in the CSS to center the category/subcategory images.

  3. On the sidebox menu where it says 'Body Jewelry' - I dont want that to link to anything, just be static. I only want the sub-categorys under it to be clickable.

I will await your reply.

Thanks in advance!
LMW1

2 Oct 2007, 11:37 AM
#6
lmw1 avatar

lmw1

Zen Follower

Join Date:
Mar 2007
Posts:
105
Plugin Contributions:
0

Re: Center Align Category/Sub-Category Images?

This might help...here's the URL.

starz body jewelry dot com

Respectfully,
LMW1

2 Oct 2007, 7:20 PM
#7
gjh42 avatar

gjh42

Black Belt

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

Re: Center Align Category/Sub-Category Images?

This is really strange.

Looking at your site with Firefox Web Developer, and also with Firebug, it appears that the class (.categoryListBoxContents) that should control that element is in the stylesheet, but is not being applied to the element. Editing does nothing, and the margin already specified there is not in use. Adding !important or adding more specificity to the selector does nothing, either.

Looking at the active stylesheet.css with Firebug shows a different set of code (missing .categoryListBoxContents) than you get when selecting "edit" in Firebug (where .categoryListBoxContents shows but does nothing).

On another topic, I notice that you have a "Powered by American WebMakers" link at the bottom of your page. It is ok to say "Site designed by..." or the like, but "Powered by" is a claim that you wrote the Zen Cart software and is not kosher.

3 Oct 2007, 4:55 AM
#8
lmw1 avatar

lmw1

Zen Follower

Join Date:
Mar 2007
Posts:
105
Plugin Contributions:
0

Re: Center Align Category/Sub-Category Images?

I'll tell my guy to change the Powered By to Designed by *(good point, sorry. Sure it was an oversite). Any ideas on how to center the category/sub-category images?

Any help would be appreciated.

Respectfully,
LMW1

3 Oct 2007, 8:36 AM
#9
gjh42 avatar

gjh42

Black Belt

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

Re: Center Align Category/Sub-Category Images?

Unfortunately, there are weird things going on with your site display/stylesheet and none of the variations I've tried on what ought to work are having any effect. I don't really know what is causing it or how to fix it.

3 Oct 2007, 12:35 PM
#10
lmw1 avatar

lmw1

Zen Follower

Join Date:
Mar 2007
Posts:
105
Plugin Contributions:
0

Re: Center Align Category/Sub-Category Images?

I believe that we can fix it.

Would you like to look at the files on my server to make sure everything looks right? I'd be happy to PM you a temporary password to the FTP site. I'd even pay you.

Let me know what you think.

Respectfully,
Len

3 Oct 2007, 5:14 PM
#11
gjh42 avatar

gjh42

Black Belt

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

Re: Center Align Category/Sub-Category Images?

If I thought the problem was in the code in a file I am familiar with, I would do it. However, I think you need someone with deep knowledge of how servers and websites work and malfunction.

4 Oct 2007, 8:40 AM
#12
lmw1 avatar

lmw1

Zen Follower

Join Date:
Mar 2007
Posts:
105
Plugin Contributions:
0

Re: Center Align Category/Sub-Category Images?

I got it fixed and working properly.

How?

I went through the entire code of the original CSS file, replaced all my color codes, re-installed it, and BINGO!!! It worked.

I must have deleted something when I was customizing the CSS the first time.

Anyways, it's working dandy now!

Thanks for your investment in time for trying to help me, I want you to know that it was and is appreciated.

Respectfully,
Len

4 Oct 2007, 3:49 PM
#13
gjh42 avatar

gjh42

Black Belt

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

Re: Center Align Category/Sub-Category Images?

I'm very glad to hear that! Those gremlins can be devious... and sometimes slip away while you're looking the other way.

8 May 2009, 5:41 PM
#14
zarahemna avatar

zarahemna

New Zenner

Join Date:
Apr 2009
Posts:
19
Plugin Contributions:
0

Re: Center Align Category/Sub-Category Images?

Any chance you could post what part of the css you needed to edit?

6 Jul 2009, 11:20 PM
#15
baltimucho avatar

baltimucho

New Zenner

Join Date:
Jun 2009
Location:
Salt Lake City
Posts:
15
Plugin Contributions:
0

Re: Center Align Category/Sub-Category Images?

I'm having the same problem, and I have tried all the CSS and "category_row.php" edits.

I just want my SubCategory text buttons to display side-by-side.

http://eternitystore.com/index.php?m...=index&cPath=9

What the freek am I doing wrong?

::mitch::

1 Feb 2011, 7:18 AM
#17
d1c2w3 avatar

d1c2w3

New Zenner

Join Date:
Nov 2010
Posts:
3
Plugin Contributions:
0

Re: Center Align Category/Sub-Category Images?

I realize this thread is a bit old, but I was having the same issue. Also, due to my ZC layout settings, by making my CSS class .categoryListBoxContents{text-align:center} or ```
.categoryListBoxContents{margin:auto;}


What I did instead was add```
.categoryListBoxContents img {margin-left:auto; margin-right:auto;}
``` to my CSS file and it corrected the image centering issue without throwing off my overall alignment. By adding " img" to the end of the class name (make sure there's a space in front of I-M-G!), it affects only the images within that div instead of everything. :smile:

Just thought I'd put that out there! I know I've been helped countless times by these threads and it annoys me when someone says "yay, I figured it out!" but then never says what they did to figure it out. :censored:

Dan