Board index PBase HTML and Style Sheets PBase CSS workarounds & tricks

HTML and Style Sheets

PBase CSS workarounds & tricks

Customize your galleries.
srijith
Moderator
 
Posts: 2321
Location: Amsterdam

PBase CSS workarounds & tricks

Post Mon Jul 28, 2003 9:35 am


Couple of notes to make your CSS work in PBase!

1)DO NOT include the
<style type="text/css"> <!--
and
--></style>
in your user defined CSS body. Pbase server will add it. If you add it, your CSS will break. Guarantee :)

2)PBase uses an invalid class name "message_body". According to the specifications, you cannot have the "_" in the class name. But since a lot of already existing stylesheets uses the "_", slug will most probably not correct the error, as it will break a lot of user's style.

So, if you still want to use valid W3 spec compliant CSS, don't you the "message_body" class at all. Rather, in your design, try to keep the properties of the area associated with class, same as that of the basic html layout. In plain speak, try to keep the color of the text and the background for the 'message_body" (the area around the comments section) the same as that of the rest of the body. Then specify all that you want in the "BODY" class.

3)Do not use "background-color:none". No one had heard of a "none" color! What you might want is "background-color:transparent". But, why specify that since by default the background-color of any class is transparent.

4)Remove classes you are not using.

5)Try not to use any IE specfic tricks, unless you want to turn away Netscape, Mozilla, Opera users.

monoprint
 
Posts: 14

Re: PBase CSS workarounds & tricks

Post Tue Jul 29, 2003 2:19 pm


[quote="srijith"]
1)DO NOT include the
<style type="text/css"> <!--
and
--></style>
in your user defined CSS body. Pbase server will add it. If you add it, your CSS will break. Guarantee :)

Um, I have this in several of my user defined sections and it works just fine. But I tried removing it as suggested, and it broke my CSS. :?:

sheila
 
Posts: 1303

List of colour "numbers"

Post Wed Jul 30, 2003 1:57 am


I know its somewhere in Photoshop, but can someone please list the "numbers" of the various colours/colors used in stylesheets? I would like to amend some of the colours but have no idea which is which? :?

Cheers
Sheila
Sheila Smart
Canon 5D Mark III; 17-40L; 24-70 f/2.8L; 70-300 f.4-5.6 L USM; 135 f/2L; 100 f/2.8 macro; 8-15 f/4 L fisheye

Blog: http://sheilasmartphotography.blogspot.com/

srijith
Moderator
 
Posts: 2321
Location: Amsterdam

Re: PBase CSS workarounds & tricks

Post Wed Jul 30, 2003 5:37 am


monoprint wrote:Um, I have this in several of my user defined sections and it works just fine. But I tried removing it as suggested, and it broke my CSS. :?:

Do you use karen1109's CSS directly or have you made your own based on that? If you are using karen1109's directly, you don't have to do anything.

I am not sure what is happening internally, but what I have seen is that when I add the :

<style type="text/css"> <!--

to my own styleheet, it breaks because somehow, the server adds a "--"
after that line. Only slug can clarify what is happening at the server side, but this has been my experience.

srijith
Moderator
 
Posts: 2321
Location: Amsterdam

Re: List of colour "numbers"

Post Wed Jul 30, 2003 5:40 am


sheila wrote: I would like to amend some of the colours but have no idea which is which? :?


Do you mean something like http://www.immigration-usa.com/html_colors.html ?

monoprint
 
Posts: 14

Re: List of colour "numbers"

Post Wed Jul 30, 2003 5:42 am


sheila wrote:I know its somewhere in Photoshop, but can someone please list the "numbers" of the various colours/colors used in stylesheets? I would like to amend some of the colours but have no idea which is which? :?



Just double click on the color boxes in the toolbar. This brings up the color picker. Look over to the right, below the RGB values and you'll see the hex value of the color selected. Be sure to check the 'Only WEB colors box' to be sure the color you select will display properly.

monoprint
 
Posts: 14

Re: PBase CSS workarounds & tricks

Post Wed Jul 30, 2003 5:50 am


srijith wrote:Do you use karen1109's CSS directly or have you made your own based on that? If you are using karen1109's directly, you don't have to do anything.



I've used the karen1109 modified with a css to change the description of most galleries.

srijith
Moderator
 
Posts: 2321
Location: Amsterdam

Re: PBase CSS workarounds & tricks

Post Wed Jul 30, 2003 6:01 am


monoprint wrote:I've used the karen1109 modified with a css to change the description of most galleries.


I am stumped.. I tried again.. I have a CSS (srijith_1) that goes:

Code: Select all
<style type="text/css">
<!--
/* Srijith's CSS - modified version of karen1109 */

BODY{
background : #464646;
margin-top: 0px;


crap crap crap


-->
</style>


Check out (view source) how it is finally output in
http://www.pbase.com/srijith/test

Noticed the "--" in line 11 of the source? That was wat I was talking about. Because of this, my CSS does not render well.

Any help slug?

slug
Site Admin
Site Admin
 
Posts: 598


Post Wed Jul 30, 2003 10:49 am


fixed i think.
i'll sit and wonder how i never noticed that before.

thanks for pointing that out.

-slug

sheila
 
Posts: 1303

Re: List of colour "numbers"

Post Thu Jul 31, 2003 12:15 am


srijith wrote:
sheila wrote: I would like to amend some of the colours but have no idea which is which? :?


Do you mean something like http://www.immigration-usa.com/html_colors.html ?


Yes - thanks a lot.

Cheers
Sheila
Sheila Smart
Canon 5D Mark III; 17-40L; 24-70 f/2.8L; 70-300 f.4-5.6 L USM; 135 f/2L; 100 f/2.8 macro; 8-15 f/4 L fisheye

Blog: http://sheilasmartphotography.blogspot.com/

sheila
 
Posts: 1303

Re: List of colour "numbers"

Post Thu Jul 31, 2003 12:16 am


monoprint wrote:
sheila wrote:I know its somewhere in Photoshop, but can someone please list the "numbers" of the various colours/colors used in stylesheets? I would like to amend some of the colours but have no idea which is which? :?



Just double click on the color boxes in the toolbar. This brings up the color picker. Look over to the right, below the RGB values and you'll see the hex value of the color selected. Be sure to check the 'Only WEB colors box' to be sure the color you select will display properly.


thanks Mono, I'll check it out.
Sheila
Sheila Smart
Canon 5D Mark III; 17-40L; 24-70 f/2.8L; 70-300 f.4-5.6 L USM; 135 f/2L; 100 f/2.8 macro; 8-15 f/4 L fisheye

Blog: http://sheilasmartphotography.blogspot.com/

srijith
Moderator
 
Posts: 2321
Location: Amsterdam


Post Thu Jul 31, 2003 12:52 am


slug wrote:fixed i think.
i'll sit and wonder how i never noticed that before.
thanks for pointing that out.

Thanks slug. So, should we or should we not include the <style> <!-- stuff in out stylesheets? or will it be inserted by the server. Or is the script smart enought to insert it when it is not in the sheet, otherwise it keeps quiet?

slug
Site Admin
Site Admin
 
Posts: 598


Post Thu Jul 31, 2003 3:11 am


srijith wrote: So, should we or should we not include the <style> <!-- stuff in out stylesheets? or will it be inserted by the server. Or is the script smart enought to insert it when it is not in the sheet, otherwise it keeps quiet?


you were correct previously.
don't include that, but the server should be smart enough to deal with it if you do. that problem with the -- was because it was almost smart enough, but not quite.

thanks,
-slug

srijith
Moderator
 
Posts: 2321
Location: Amsterdam


Post Thu Jul 31, 2003 5:56 am


slug wrote:you were correct previously.
don't include that, but the server should be smart enough to deal with it if you do. that problem with the -- was because it was almost smart enough, but not quite.

Thanks slug. Clarification appreciated, especially since it proved I was right ;)


Board index PBase HTML and Style Sheets PBase CSS workarounds & tricks

Who is online

Users browsing this forum: No registered users and 2 guests