473,545 Members | 1,638 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

how to change font colour

DP
hi,

i've got this peice of code;

<script language= "JavaScript ">
var today = new Date();
var hourOfDay = today.getHours( );
var message = " and welcome to MIS ";
if (hourOfDay >=0 && hourOfDay < 12)
{
message="Good Morning"+messag e;
}
else if (hourOfDay < 17)
{
message="Good Afternoon"+mess age;
}
else
{
message="Good Evening"+messag e;
}

document.write (message) ;
</script>

how do i display it in 'dark blue'.

thanx

devin
Jan 17 '06 #1
3 1639
DP wrote:
i've got this peice of code;

<script language= "JavaScript ">
var today = new Date();
var hourOfDay = today.getHours( );
var message = " and welcome to MIS ";
if (hourOfDay >=0 && hourOfDay < 12)
{
message="Good Morning"+messag e;
}
else if (hourOfDay < 17)
{
message="Good Afternoon"+mess age;
}
else
{
message="Good Evening"+messag e;
}

document.write (message) ;
</script>

how do i display it in 'dark blue'.


<pre style="color:#0 03; background-color:inherit">
&lt;script language= "JavaScript"&gt ;
var today = new Date();
var hourOfDay = today.getHours( );
var message = " and welcome to MIS ";
if (hourOfDay &gt;=0 && hourOfDay &gt; 12)
{
message="Good Morning"+messag e;
}
else if (hourOfDay &lt; 17)
{
message="Good Afternoon"+mess age;
}
else
{
message="Good Evening"+messag e;
}

document.write (message) ;
&lt;/script&gt;
</pre>
HTH

PointedEars
Jan 17 '06 #2
DP
that didint do anything m8?

i cant see any text now. i'm trying to display the message bit in blue.
in a web page.

thanx

devin

"Thomas 'PointedEars' Lahn" <Po*********@we b.de> wrote in message
news:57******** ********@Pointe dEars.de...
DP wrote:
i've got this peice of code;

<script language= "JavaScript ">
var today = new Date();
var hourOfDay = today.getHours( );
var message = " and welcome to MIS ";
if (hourOfDay >=0 && hourOfDay < 12)
{
message="Good Morning"+messag e;
}
else if (hourOfDay < 17)
{
message="Good Afternoon"+mess age;
}
else
{
message="Good Evening"+messag e;
}

document.write (message) ;
</script>

how do i display it in 'dark blue'.


<pre style="color:#0 03; background-color:inherit">
&lt;script language= "JavaScript"&gt ;
var today = new Date();
var hourOfDay = today.getHours( );
var message = " and welcome to MIS ";
if (hourOfDay &gt;=0 && hourOfDay &gt; 12)
{
message="Good Morning"+messag e;
}
else if (hourOfDay &lt; 17)
{
message="Good Afternoon"+mess age;
}
else
{
message="Good Evening"+messag e;
}

document.write (message) ;
&lt;/script&gt;
</pre>
HTH

PointedEars

Jan 18 '06 #3
DP
s'ok

i sorted it now. thanx for the help.

dev

"DP" <DP@hotmail.com > wrote in message
news:ZZ******** *******@newsfe7-gui.ntli.net...
that didint do anything m8?

i cant see any text now. i'm trying to display the message bit in blue.
in a web page.

thanx

devin

"Thomas 'PointedEars' Lahn" <Po*********@we b.de> wrote in message
news:57******** ********@Pointe dEars.de...
DP wrote:
i've got this peice of code;

<script language= "JavaScript ">
var today = new Date();
var hourOfDay = today.getHours( );
var message = " and welcome to MIS ";
if (hourOfDay >=0 && hourOfDay < 12)
{
message="Good Morning"+messag e;
}
else if (hourOfDay < 17)
{
message="Good Afternoon"+mess age;
}
else
{
message="Good Evening"+messag e;
}

document.write (message) ;
</script>

how do i display it in 'dark blue'.


<pre style="color:#0 03; background-color:inherit">
&lt;script language= "JavaScript"&gt ;
var today = new Date();
var hourOfDay = today.getHours( );
var message = " and welcome to MIS ";
if (hourOfDay &gt;=0 && hourOfDay &gt; 12)
{
message="Good Morning"+messag e;
}
else if (hourOfDay &lt; 17)
{
message="Good Afternoon"+mess age;
}
else
{
message="Good Evening"+messag e;
}

document.write (message) ;
&lt;/script&gt;
</pre>
HTH

PointedEars


Jan 18 '06 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

6
5221
by: Louise | last post by:
Hi I have written an HTML pages which does not have any colour specifying tags as far I know. When I view this in an Microsoft internet explorer browser it appears with a white background and black text but when I change Windows start menu->settings->control panel ->display -> appearance and change scheme to 'High Contrast Black' the...
14
2641
by: Viken Karaguesian | last post by:
Hello all, It stinks being a newbie! One thing that I'm not sure about with CSS is: where is the "proper" place to put font attibutes? This has me a little confused. Take the below style sheet (which is a work in progress) as an example. If I don't put the font attributes in the <body> <p> and <td> tags, the font will not appear the way I...
4
2961
by: ACaunter | last post by:
Hi there, I was wondering if there was a way to change the font color of the text in the title bar... by default the title bar is that dark blue faiding into light blue and it has white text... is it possible to change the color of that blue bar and also the color of the text, for all the people who visit the asp.net website... really i...
3
2136
by: Simon Gare | last post by:
Hi, trying to hide zero values by changing the colour of the font, problem is it is still printing in a light grey colour? Code below but cant work out where it is going wrong. <td width="45"<% ThisNumber = FormatNumber((DriverPayments.Fields.Item("CarParkToDriver").Value), -1, -2,
0
1585
by: Badino | last post by:
Hi, Can someone tell me what to put in this code so that if a user selects 0 (Black) then make the font white (0) as my default colour is black on my Excel spreadsheet. Private Type CHOOSECOLOUR lStructSize As Long hwndOwner As Long Hinstance As Long rgbResult As Long lpCustColors As String
3
3596
by: Johny | last post by:
I use PIL to write some text to a picture.The text must be seen wery clearly. I write the text to different pictures but to the same position. As pictures maybe different, colour, in the position where I write the text, is also different. Is there a way how to set the font colour so that it will be seen very clearly in the picture? For...
0
1136
by: Johny | last post by:
I use PIL to write some text to a picture.The text must be seen wery clearly. I write the text to different pictures but to the same position. As pictures maybe different, colour, in the position where I write the text, is also different. Is there a way how to set the font colour so that it will be seen very clearly in the picture? For...
3
4235
by: DNolan | last post by:
Hello, I was wondering if anyone could help me. I have an access form with tabbed pages on it. I would like the colour of the tab name to change when a user inputs information into the fields on the page, i.e when they start a new record all the tabbed pages have their name in black and when they input info into a page the font colour of...
3
5612
by: Phil Stanton | last post by:
Correct me if I'm wrong, but is it impossible to change the font in a report field when in print preview (MDE database) or can it only be done in design view in the MDB database. Part of my database is used to print name tags for functions, and it would be nice for the operator to have a choice of different fonts, colours and backgrounds. I...
6
4505
by: gavy7210 | last post by:
hello i am using struts 1.2,Eclipse Platform Version: 3.4.2,mySql 5.0.1,jdk 1.5.. i have a login form(jsp) in which a user logs in,in case he doesnt enter his username and/or password an error is displayed using the <ul> tag and <html:errors> in the jsp. in the from class a vaidate method creates an actionerrors object adds all the errors to...
0
7459
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main...
1
7411
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For...
0
7749
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the...
0
5965
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then...
0
4942
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert...
0
3444
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in...
0
3439
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
1871
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
0
695
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.