Zen Cart Logo
Forums / Templates, Stylesheets, Page Layout / Centering categories in main wrapper

Centering categories in main wrapper

Views: 654

Results 1 to 7 of 7
15 Jan 2011, 12:16 AM
#1
richphitzwell avatar

richphitzwell

Zen Follower

Join Date:
Jul 2010
Location:
My heart will always be in the NorEast
Posts:
110
Plugin Contributions:
0

Centering categories in main wrapper

have attempted to place a text-align:center in pretty much all the wrappers and its still going to the left or right if I change the float.

How can I go about centering this as I have an odd number of categories and or I may add more at a later date. This is only happening on the index page.

Also if anybody knows of a script that can automate qr's for each product that would be grand, but thats for another day.

15 Jan 2011, 12:42 AM
#2
gjh42 avatar

gjh42

Black Belt

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

Re: Centering categories in main wrapper

automate qr's? What do you mean?

There is no way to center those last two categories automatically without a bunch of custom coding. You can get the effect for your particular current display with CSS, using the "adjacent selector" operator, similar to this:

.categoryListBoxContents+.categoryListBoxContents+.categoryListBoxContents+br+.categoryListBoxContents {margin-left: 123px;}

This would have to be customized to exactly fit the sequence you have, including a br if there is one. If I saw your page live, I could write the correct rule quickly.

15 Jan 2011, 12:56 AM
#3
richphitzwell avatar

richphitzwell

Zen Follower

Join Date:
Jul 2010
Location:
My heart will always be in the NorEast
Posts:
110
Plugin Contributions:
0

Re: Centering categories in main wrapper

Thanks, ill try it later.

I have qr's on every product that directs smartphones back to the specific product. Unfortunately I have been sucking it up and manually doing this which brings up a couple of issues, one being time, and two being if I move a product or category to someplace else it would invalidate the code.

If someone came up with a qr generator script that would poll whatever the url is to the product on the fly that would be awesome!

**I just looked at your code, didnt even think about nudging it over! Simple solution thanks

15 Jan 2011, 1:07 AM
#4
richphitzwell avatar

richphitzwell

Zen Follower

Join Date:
Jul 2010
Location:
My heart will always be in the NorEast
Posts:
110
Plugin Contributions:
0

Re: Centering categories in main wrapper

WORKED LIKE A CHARM!!!!!!!! Thank you so much :clap: :bigups:

15 Jan 2011, 2:06 AM
#6
richphitzwell avatar

richphitzwell

Zen Follower

Join Date:
Jul 2010
Location:
My heart will always be in the NorEast
Posts:
110
Plugin Contributions:
0

Re: Centering categories in main wrapper

Quick answer, anything I want it to. Your phone scans it in this case it will pull up that specific product on the phone. I have others on sites that will add contact vcards to the persons phone. At businesses I have the wifi information on it so they scan and all the encryption said etc configure the phone to the network. Hell I can put a nice message on your phone like hi!

I've been putting these up for a year now and just in the last month they are becoming common on business cards, bills, whatever.

15 Jan 2011, 2:49 AM
#7
gjh42 avatar

gjh42

Black Belt

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

Re: Centering categories in main wrapper

I've seen them here and there and obviously they have coded information, but that's all I knew (didn't know what they were called either).