Board index PBase HTML and Style Sheets Pictures in Title field..?

HTML and Style Sheets

Pictures in Title field..?

Customize your galleries.
zevs
 
Posts: 67

Pictures in Title field..?

Post Sun Sep 12, 2004 9:49 am


Hi!

Is there any way to put images into the Title field of a page? I don't mean a common picture for all galleries, but a unique picture for each gallery? I know you can put it into the Description field, but for different reasons I would like to be able to have it also in the title.

Zevs

dpnew
 
Posts: 26

Re: Pictures in Title field..?

Post Wed Sep 15, 2004 8:23 am


zevs wrote:Hi!

Is there any way to put images into the Title field of a page? I don't mean a common picture for all galleries, but a unique picture for each gallery? I know you can put it into the Description field, but for different reasons I would like to be able to have it also in the title.

Zevs


Sure. Every gallery is controlled by its own stylesheet. If you pick a sample style that has a title, you can modify the style of the title and add a background image. For instance, the alexc style has an element for the title:

<h2>some text</h2>

which is styled with this part of the css stylesheet:

h2
{
font-size: 12pt;
font-weight: normal;
text-align: right;
letter-spacing: 8px;
padding-top: 15px;
padding-bottom: 15px;
margin-left: 2px;
margin-right: 2px;
background-color: black;
color: white;
}

You can add a background image to the title with lines like these:

background-image: url(http://www.pbase.com/xxx/45686792.jpg);
background-repeat: no-repeat;
background-position: top left;
height: 100px;

Don't forget to add .jpg onto the end of the image url.
Adjust the 'height' based on the image height.

You can make a version of that style sheet for every gallery with a different url for the image.

Since the image is a background image, if you start the text of the title on the left, the text will be on top of your image. If you don't want that, then you can add some padding to the left with a line like this:

padding-left: 150px;

zevs
 
Posts: 67


Post Wed Sep 15, 2004 6:57 pm


Thanks very much dpnew!!!!!!!

You are right of course if one uses separate style sheets for those galleries that will work. Why didn't I think of that! I guess I was so locked into hoping that there was some way of avoiding it, but your solution is great!

Thanks again for all the help !!!!!

Zevs


Board index PBase HTML and Style Sheets Pictures in Title field..?

Who is online

Users browsing this forum: ClaudeBot and 0 guests