View Full Version : cannot center a banner
tienshanman
Dec-27-2008, 08:09 AM
I just created a banner and it appeared on my site, no problem. Except that I cannot seem to center it. I have added: <div align="center"> in the custom header section but that does not seem to do the trick. What am I doing wrong? http://karlherrington.smugmug.com
jfriend
Dec-27-2008, 08:14 AM
First of all, your banner image (http://karlherrington.smugmug.com/photos/443610851_QXpTc-L.jpg) is not visible to the rest of us. To be visible to the public, all of the following must be true.
External linking must be enabled in the gallery
The gallery must not be password protected (it can be unlisted if you want)
The image itself must not be marked [x] hidden in the gallery because then only you would see it
You must enable public access to the size that you are linking to
You must have the correct URL to direct link to the imageIn your case, I would guess that it's the first or third point. If you can't figure out why it won't show for us, then post a link to the gallery it's in and I can probably tell which issue it is. When the image is showing, then I can help you center it.
Also, you have a lone <div align="center"> after your banner. Please remove that. It has no matching </div> tag and can goof up the formatting of your page.
In looking at your CSS, I see you have:
#my_banner {
width: 900px;
height: 217px;
margin: 0 auto;
background: url(http://karlherrington.smugmug.com/photos/443610851_QXpTc-L.jpg) no-repeat;
}
The width and height need to match the image you are using. Since you're linking to the L size of the image, I don't' think there's any way it can be 900px wide. That is probably why your banner won't center. Put the right height and width in for the size of the specific image that you are linking to (which is the L size, not the original size).
vBulletin® v3.8.5, Copyright ©2000-2012, Jelsoft Enterprises Ltd.