Milonic provide full featured pull down web menus for some of the worlds largest companies
click here to see what it can do for you

Download Milonic DHTML Menu
Buy Milonic DHTML Menu

Back To Start Of Archive
Taken From The Forum: Help & Support for DHTML Menu Version 5+
Forum Topic: Click to view post
Last Updated: Saturday July 14 2012 - 06:07:34

change font color on text in main menu?


Poster: rudy
Dated: Thursday April 1 2004 - 16:55:22 BST

I want to change the font color on the word "Logout" to the color red on the last line of the following code:
Code:
with(milonic=new menuname("Main Menu")){
style=windows98style;
top=7;
screenposition="center";
alwaysvisible=1;
orientation="horizontal";
aI("text=Motherboards;showmenu=Motherboards;status=Getting to Know Your Motherboard");
aI("text=Drag-n-Drop;showmenu=Drag and Drop;status=Drag-n-Drop Components to the Motherboard;");
aI("text=A+ Jeopardy;showmenu=AP Jeopardy;status=A+ Jeopardy;");
aI("text=Search Engine;showmenu=Acronyms;status=Extensive Acronym Lookup and Glossary of Computer Terms;");
aI("text=Hard Drives;showmenu=Hard Drive;status=Understanding Hard Drives;");
aI("text=Logout;url=http://www.networkdriven.com/index22.html;status=Back To Home Page;");
}


I want to use the correct syntax so that it should work in all browsers if possible. My first thought is to do it like this:

Code:
aI("text=<font color="#FF0000">Logout</font>;url=http://www.networkdriven.com/index22.html;status=Back To Home Page;");


but I don't know if this will work or work in all browsers?

Your help would be appreciated :D


Poster: Maz
Dated: Thursday April 1 2004 - 17:24:15 BST

You can change oncolor=#FF0000; and offcolor=#FF0000; or whatever color you want by adding it to the menu item.

Just don't include the quotes.

maz

Change font color


Poster: rudy
Dated: Thursday April 1 2004 - 17:37:37 BST

Thanks Maz for the quick reply.

What I didn't explain very well was that I need the text to be red all the time, not just when moused-over.


Poster: Ruth
Dated: Thursday April 1 2004 - 17:42:20 BST

Hi Rudy,
If you use what Maz gave you then it would be red all the time since both the on and off color would be the same.

Ruth


Poster: rudy
Dated: Thursday April 1 2004 - 17:49:43 BST

Dah :oops:

My appologies to Maz and Ruth...

Didn't notice that the color code ff0000 was the same for both on and off.

Thanks to you both !!!

Change font color of text


Poster: rudy
Dated: Thursday April 1 2004 - 18:11:26 BST

I have tried adding the oncolor and offcolor as follows but obviously this is not correct...

Any help appreciated...

aI("text=oncolor=#FF0000;Logout; offcolor=#FF0000;url=http://www.networkdriven.com/index22.html;status=Back To Home Page;");
}


Poster: Maz
Dated: Thursday April 1 2004 - 18:19:33 BST

Rudy,

keep it simple ;)

aI("text=Logout;oncolor=#FF0000;offcolor=#FF0000;url=http://www.networkdriven.com/index22.html;status=Back To Home Page;");
}

Most styles can be added to a single menu item like this.

maz

Change font color


Poster: rudy
Dated: Thursday April 1 2004 - 18:30:26 BST

Thanks Maz,

That did the trick :D

Glad your here to help us out!!!