center margin Bulletproof

Skinning and designing Serendipity (CSS, HTML, Smarty)
Post Reply
ed587
Regular
Posts: 75
Joined: Thu Feb 12, 2009 3:26 pm

center margin Bulletproof

Post by ed587 »

I switched templates to Bulletproof but I can't seem to get the content of my html nuggets to center in my single right margin. Tried doing it the way I did it using the Joshua template: <p align="center"> with no luck. Changed the style.css to auto from 0:
/*** Sidebar styles ***/
.serendipitySideBarItem {
margin: auto;
}

.serendipitySideBarTitle {
margin: auto;
}

.serendipitySideBarContent {
margin: auto;
}
Then simply selected the image and centered in the editor with no luck. I am in the process of narrowing my entries to fit in Bulletproof but on the first page I don't think wide entries are the issue. If you want to see, it is at http://www.neterm.net/serendipity

Thanks,
~Ed587
The best,

~Ed
judebert
Regular
Posts: 2478
Joined: Sat Oct 15, 2005 6:57 am
Location: Orlando, FL
Contact:

Re: center margin Bulletproof

Post by judebert »

I notice all the stuff you want centered is in a paragraph. You can change its inline style to:

Code: Select all

<p style="text-align: center;">
Judebert
---
Website | Wishlist | PayPal
ed587
Regular
Posts: 75
Joined: Thu Feb 12, 2009 3:26 pm

Re: center margin Bulletproof

Post by ed587 »

The nuggets that are text ARE centering. It is the images that are not. Also, is the width of the margin in bullet proof determined by the width of an image? Maybe my images are too wide?
The best,

~Ed
ed587
Regular
Posts: 75
Joined: Thu Feb 12, 2009 3:26 pm

Re: center margin Bulletproof

Post by ed587 »

Okay, I got the images to center by putting them in a centered table. I know there must be a better way to do it with a <div>. I will work on it. Thanks.
The best,

~Ed
Don Chambers
Regular
Posts: 3657
Joined: Mon Feb 13, 2006 2:40 am
Location: Chicago, IL, USA
Contact:

Re: center margin Bulletproof

Post by Don Chambers »

If you are placing your image within a <p>aragraph in bulletproof, try this:

Code: Select all

<p class="serendipity_center">
    <img blah blah />
</p>
=Don=
ed587
Regular
Posts: 75
Joined: Thu Feb 12, 2009 3:26 pm

Re: center margin Bulletproof

Post by ed587 »

Don Chambers wrote:If you are placing your image within a <p>aragraph in bulletproof, try this:

Code: Select all

<p class="serendipity_center">
    <img blah blah />
</p>
That's working! :D Thanks!
The best,

~Ed
Don Chambers
Regular
Posts: 3657
Joined: Mon Feb 13, 2006 2:40 am
Location: Chicago, IL, USA
Contact:

Re: center margin Bulletproof

Post by Don Chambers »

Great! And so there is no misunderstanding, that is a class in bulletproof - some other templates have it too, doing much the same thing which is text-align: center and margin: 0 auto. If you switched templates, it may, or may not, continue to work as expected unless you revised the nugget or a different template's stylesheet.
=Don=
Post Reply