Board index PBase HTML and Style Sheets Pictures Captions

HTML and Style Sheets

Pictures Captions

Customize your galleries.
michel_5169
 
Posts: 16

Pictures Captions

Post Fri Apr 16, 2004 9:26 am


Hello,
how to modify the size, the color and the background of the caption under the full picture ?
(Pïcture 1.jpg....)

michel_5169
 
Posts: 16


Post Fri Apr 16, 2004 10:22 am


When I edit the "CSS" H3, the background color change, but the font size not !
What line can I write for that ?

srijith
Moderator
 
Posts: 2321
Location: Amsterdam


Post Fri Apr 16, 2004 10:45 am


In H3 put something like
Code: Select all
font-size: 18px;

Change 18 to a value you like.

michel_5169
 
Posts: 16


Post Fri Apr 16, 2004 11:21 am


Thanks, but no change !
Please look at the normally h3:

border-bottom: rgb(0, 0, 0) 1px dotted;
border-left: 1px none;
border-right: 1px none;
border-top: 1px none;
padding: 2px;
width: 400px;
display: block;
background: rgb(150, 40, 80);
color:#CCCCCC;
font: 10px;
font-weight: normal;
letter-spacing: 0px;
text-align: center;

I have font = 10 px: I modify this line or
where I write the line code ?

justplanecrazy
 
Posts: 4


Post Sun May 09, 2004 2:40 am


I'm having the same problem, the caption below each picture is very large even though the H3 font-size is only 12px.

alangrant
 
Posts: 861


Post Sun May 09, 2004 12:29 pm


This is an interesting quirk which I don't remember seeing discussed here before.

I think the problem here is that the title is wrapped inside not just H3 but also a SPAN with class "title" (see the source code). The span will override the H3 settings.

In the default pbase stylesheet [http://image.pbase.com/styles/gallery2.css] there is a section:
.title {
font-size: 14pt;
font-weight: bold;
text-align: center;
}

This explains why you could change the background but not the font-size. Your font-size setting is being overidden by the SPAN setting of 14pt.

You need to add a .title section to your CSS and set the font-size in that. Or you could probably just combine with H3, i.e.

H3, span.title
{
...
}

But check for side effects, I don't know if .title is used anywhere else.
Alan
Travel Photos - http://www.pbase.com/alangrant
Balkanology: Explore Southeast Europe - http://www.balkanology.com/

arjunrc
 
Posts: 1003

I Agree - generated pbase HTML is no where close to clean

Post Sun May 09, 2004 1:06 pm


I really wish the programmers of pbase clean up their
generated HTML code in newer versions.

There are simply too many quirks to watch out for when you attempt to change such things.

regds
arjun

slug
Site Admin
Site Admin
 
Posts: 598


Post Sun May 09, 2004 1:24 pm


the html is ungood because when i started, i barely knew html and didn't know what a CSS was.
then one day i discovered CSS and so started putting a few classes here and there.
this random growth continued but the whole time being constrained by any old classes. don't want to change too much because people have built stylesheets around the existing html.

what i need to do is enlist the help of a designer who is an expert with HTML/CSS to design the ideal HTML for the gallery and image pages.
then galleries will have a version number. existing galleries will be v1, and any new ones will be v2.
v1 galleries will use the old html and be compatible with old stylesheets so nothing will break unless you specifically choose to change to v2.

probably v2 html should avoid all TABLEs and use DIVs and SPANs etc, but i'm no CSS expert which is why i haven't done this myself.

-slug

arjunrc
 
Posts: 1003


Post Sun May 09, 2004 3:10 pm


I can fully appreciate the evolution as you describe it, since my familiarity of perl, HTML and CSS went pretty much the same way, all starting with my trying to spruce up my pbase site.

I would certainly be glad to test/comment/contribute in any way to such efforts and sincerely hope someone with more prolonged exposure to correct CSS coding would respond to your help request. I fear my CSS familiarity is closer to 'given a problem, how does one hack it' and not 'how do I code it the right way' which ofcourse is a fundamental 'anti-christ' to good design principles ;-)

regds
arjun


Board index PBase HTML and Style Sheets Pictures Captions

Who is online

Users browsing this forum: ClaudeBot and 1 guest