Tycoon Talk
Become a Big fish!
The number 1 forum for online business!
Post topics, ask questions, share your knowledge.
Tycoon Talk is part of Freelancer.com - find skilled workers online at a fraction of the cost.

HTML Forum


You are currently viewing our HTML Forum as a guest. Please register to participate.
Login



Post a Project »

Find a Professional HTML Freelancer!

Find a Freelancer to help you with your HTML projects

FREE Outsourcing eBook!

Reply
Old 08-03-2007, 02:53 PM rgb function
Nathand's Avatar
Extreme Talker

Posts: 233
Location: USA
Trades: 0
Hi, when I use "<body bgcolor="rgb(200,200,200)">" in Internet Explorer it works fine, as expected. But when I try and use it in Firefox the page always shows up as black? Is there a workaround for this?

Thanks,
Nathan
Nathand is offline
Reply With Quote
View Public Profile
 
 
Register now for full access!
Old 08-03-2007, 03:29 PM Re: rgb function
bas
Super Talker

Posts: 108
Name: Bas
Trades: 0
Using hexadecimal color-codes Works fine in all browsers, So rgb(200, 200, 200) would become #c8c8c8.
Code:
 <body bgcolor="#c8c8c8">
Or the better way with CSS:
Code:
 <body style=”background:#c8c8c8;”>
bas is offline
Reply With Quote
View Public Profile
 
Old 08-03-2007, 03:30 PM Re: rgb function
JamieLewis's Avatar
Pretty Much a Big Deal...

Latest Blog Post:
Gooie
Posts: 385
Name: Jamie Lewis
Location: UK
Trades: 0
You could try using CSS, either in an external file(recommended) or inline. For inline CSS try putting:

Code:
<style>
body{
background:rgb(200,200,200);
}
</style>
in the head part of your document.

Or


Code:
<body style="background:rgb(200,200,200);">
in your code.

Hope that helped.

Jamie

Last edited by JamieLewis; 08-03-2007 at 03:47 PM..
JamieLewis is offline
Reply With Quote
View Public Profile Visit JamieLewis's homepage!
 
Old 08-03-2007, 03:40 PM Re: rgb function
bas
Super Talker

Posts: 108
Name: Bas
Trades: 0
Quote:
Originally Posted by JamieLewis View Post
Code:
<body style="background:background:rgb(200,200,200);">
1x "background:" then , so:

Code:
<body style="background:rgb(200,200,200);">
bas is offline
Reply With Quote
View Public Profile
 
Old 08-03-2007, 03:47 PM Re: rgb function
JamieLewis's Avatar
Pretty Much a Big Deal...

Latest Blog Post:
Gooie
Posts: 385
Name: Jamie Lewis
Location: UK
Trades: 0
Ha, blame my lack of thought while typing on that
JamieLewis is offline
Reply With Quote
View Public Profile Visit JamieLewis's homepage!
 
Old 08-03-2007, 06:48 PM Re: rgb function
Nathand's Avatar
Extreme Talker

Posts: 233
Location: USA
Trades: 0
Great thanks. @bas - How do you get the hexadecimal color code from an rgb value?

Thanks again,
Nathand
Nathand is offline
Reply With Quote
View Public Profile
 
Old 08-03-2007, 08:40 PM Re: rgb function
LadynRed's Avatar
Defies a Status

Posts: 10,017
Location: Tennessee
Trades: 0
Try this: http://www.pitt.edu/~nisg/cis/web/cgi/rgb.html

Converter here: http://www.javascripter.net/faq/rgbtohex.htm

RGB to Hex color picker tool: http://mediagods.com/tools/rgb2hex.html
__________________
Web Goddess & Web Standards Evangelist :) - Tables Be Gone !!

Please login or register to view this content. Registration is FREE


Please login or register to view this content. Registration is FREE

LadynRed is offline
Reply With Quote
View Public Profile
 
Old 08-03-2007, 09:00 PM Re: rgb function
Nathand's Avatar
Extreme Talker

Posts: 233
Location: USA
Trades: 0
Thanks a lot.
Nathand is offline
Reply With Quote
View Public Profile
 
Old 08-03-2007, 09:49 PM Re: rgb function
ForrestCroce's Avatar
Half Man, Half Amazing

Posts: 3,023
Name: Forrest Croce
Location: Seattle, WA
Trades: 0
Quote:
Originally Posted by Nathand View Post
Great thanks. @bas - How do you get the hexadecimal color code from an rgb value?
Hex color codes are RGB values. They're just expressed in a different format.

Pure red = rgb(255, 0, 0) = #FF0000
Pure green = rgb(0, 255, 0) = #00FF00
Pure blue = rgb(0, 0, 255) = #0000FF
__________________

Please login or register to view this content. Registration is FREE
|
Please login or register to view this content. Registration is FREE
|
Please login or register to view this content. Registration is FREE
ForrestCroce is offline
Reply With Quote
View Public Profile Visit ForrestCroce's homepage!
 
Reply     « Reply to rgb function
 

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off





   
RSS Feed  Feeds: RSS   JS   XML
RSS Feed  Feeds for this forum: RSS   JS   XML



Page generated in 0.93962 seconds with 12 queries