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.

CSS Forum


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



Reply
Two small problems in css
Old 07-01-2006, 04:38 PM Two small problems in css
Mong's Avatar
Skilled Talker

Posts: 72
Location: floating on the C
Trades: 0
First check this menu test page (in firefox)
http://www.nichewatch.com/menus/code.php

Now when i hover over "Stat" submenu is displayed.

1) I want there should be only outer border for submenu and there should be complete white background of submenu without separating orange color between submenu items.

2) When i hover over "Stat" and move mouse to submenu items; background color of "Stat" goes back to orange but i want to keep it white same as when mouse hovers it.

Thanks for your time and help
__________________
███ Yeaaa Yeaaa ;) its free
Please login or register to view this content. Registration is FREE

███ Cool Firefox Extension Available
Please login or register to view this content. Registration is FREE
Mong is offline
Reply With Quote
View Public Profile Visit Mong's homepage!
 
 
Register now for full access!
Old 07-01-2006, 05:45 PM Re: Two small problems in css
chrishirst's Avatar
Missing! presumed drunk.

Posts: 41,517
Name: Chris Hirst
Location: Blackpool. UK
Trades: 0
Quote:
Now when i hover over "Stat" submenu is displayed.
There isn't in Internet Explorer.
IE doesn't support hover on arbitary elements, only on anchors <a>

1) just specify which edges the border should be on. border-color: top right bottom left is the order.

2) use javascript to set the background colour of the parent element.
__________________
Chris. ->> Links are advertising NOT optimising!! <<-
A foolish consistency is the hobgoblin of little minds
Thought for today:- I SEO the only industry where all the cowboys are Indians?

Last edited by chrishirst; 07-01-2006 at 05:46 PM..
chrishirst is online now
Reply With Quote
View Public Profile Visit chrishirst's homepage!
 
Old 07-02-2006, 01:41 AM Re: Two small problems in css
Mong's Avatar
Skilled Talker

Posts: 72
Location: floating on the C
Trades: 0
chris i made clear that please test in firefox only
I will later make it compatible with IE.
__________________
███ Yeaaa Yeaaa ;) its free
Please login or register to view this content. Registration is FREE

███ Cool Firefox Extension Available
Please login or register to view this content. Registration is FREE
Mong is offline
Reply With Quote
View Public Profile Visit Mong's homepage!
 
Old 07-02-2006, 03:37 AM Re: Two small problems in css
chrishirst's Avatar
Missing! presumed drunk.

Posts: 41,517
Name: Chris Hirst
Location: Blackpool. UK
Trades: 0
Why would you want to go back and rework something for such a simple fix at this point ??

simply make the <a>s into block elements ( display:block; ) and apply the hover to that
__________________
Chris. ->> Links are advertising NOT optimising!! <<-
A foolish consistency is the hobgoblin of little minds
Thought for today:- I SEO the only industry where all the cowboys are Indians?
chrishirst is online now
Reply With Quote
View Public Profile Visit chrishirst's homepage!
 
Old 07-02-2006, 01:58 PM Re: Two small problems in css
LadynRed's Avatar
Defies a Status

Posts: 10,016
Location: Tennessee
Trades: 0
Right, but there is a way to make hover's work on none-link elements.

csshover. htc.. a bit of script -- very easy to use

http://www.xs4all.nl/~peterned/csshover.html

Your all-around border is coming from here:
Quote:
#menu a, #menu h2 {
font: bold 13px Verdana, Arial, Helvetica, sans-serif;
display: block;
border-width: 1px;
border-style: solid;
border-color: #FD7D41;
margin: 0;
padding: 2px 3px;
}
Your orange background on the submenu is coming from this section:
Quote:
div#menu ul ul ul li a:hover
{
color: #fff;
background: #FD7D41;

}
IF you want a white background on the submenu, you are going to have to choose a different color for the text or you'll have white on white.

If you change those 2 sections to this - you might have what you want - white bg and a solild right border only.

Quote:
div#menu ul ul li:hover ul a
{
font: 11px Verdana, Arial, Helvetica, sans-serif;
color: #FD7D41;
background: #fff;
/*border-width: 1px;
border-color: #FD7D41;*/

}

div#menu ul ul ul li a:hover
{
color: #fd7d41;
/*background: #FD7D41;*/
border-right: 1px solid #fd7d41;
}
__________________
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


Last edited by LadynRed; 07-02-2006 at 02:15 PM..
LadynRed is offline
Reply With Quote
View Public Profile
 
Old 07-02-2006, 02:09 PM Re: Two small problems in css
Extreme Talker

Posts: 170
Location: Canada
Trades: 0
But your border attribute around the ul instead of the li for the sub-menu and you should lose the seperating lines.
Code:
ul#submenu {
border: 1px solid orange;
}

li#submenu {
border: 0;
}
I believe I may have misinterpretted your question though...
__________________

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



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

Last edited by collyer_1; 07-02-2006 at 02:15 PM..
collyer_1 is offline
Reply With Quote
View Public Profile Visit collyer_1's homepage!
 
Old 07-02-2006, 04:12 PM Re: Two small problems in css
Mong's Avatar
Skilled Talker

Posts: 72
Location: floating on the C
Trades: 0
Thanks LadynREd and Colyer.

BUT it doesn't work at all.

For more details

I want menu should look like this

when mouse should be over "STAT".

I want sub-menu should look like this


when mouse should be over sub-menu item(in example "Previous Tournament").


Now i think it would be very easy for you to help me

Thank You.
__________________
███ Yeaaa Yeaaa ;) its free
Please login or register to view this content. Registration is FREE

███ Cool Firefox Extension Available
Please login or register to view this content. Registration is FREE

Last edited by Mong; 07-03-2006 at 04:05 PM..
Mong is offline
Reply With Quote
View Public Profile Visit Mong's homepage!
 
Old 07-03-2006, 11:59 AM Re: Two small problems in css
LadynRed's Avatar
Defies a Status

Posts: 10,016
Location: Tennessee
Trades: 0
Do you want help, or do you want us to do it FOR you. I showed you where your major complaints were in your code, you should be able to solve this yourself knowing where you need to change.

IF you want it white on orange on hover, then you need to code the hover state that way.
If you want just an outline on the entire sub-menu area, then you need to add the border: 1px solid orange; where you want it.
__________________
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 07-03-2006, 06:38 PM Re: Two small problems in css
kIDJOE's Avatar
Extreme Talker

Posts: 186
Location: Hollywood, CA
Trades: 0
I think I understand that you are trying to keep the menu highlighted even when your are Over the Sub Menu? for this you will need to use Jaavscript and hiddent text Fields as FLAGS. when you do your first OnMouseOver you will also need to change the value of yone of your flags, and set that If the value of that flag == '1' then Return False on the OnMouseOut and when you are ready to set your button to its original state you will have to set the value of the same flag to '0' or whatever you call your variables.

OnmouseOver:if (document.FORMNAME.FLAG1.value == '0'){ChangeBackgroundClassOrFunction();}

OnMouseOut:if (document.FORMNAME.FLAG1.value == '1'){BackChangeBackgroundClassOrFunction();}

+ Reset the value to original state.

I hope I make myself clear is a bit complicated if you dont understand Flags. Hope you do!

Good luck
__________________

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
-
Please login or register to view this content. Registration is FREE

kIDJOE is offline
Reply With Quote
View Public Profile Visit kIDJOE's homepage!
 
Old 07-05-2006, 11:19 AM Re: Two small problems in css
LadynRed's Avatar
Defies a Status

Posts: 10,016
Location: Tennessee
Trades: 0
Quote:
for this you will need to use Jaavscript and hiddent text Fields as FLAGS.
No, you don't. There are ways to achieve this in CSS w/o the use of scripts.
__________________
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 07-06-2006, 03:16 PM Re: Two small problems in css
kIDJOE's Avatar
Extreme Talker

Posts: 186
Location: Hollywood, CA
Trades: 0
I would love to see it.

__________________

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
-
Please login or register to view this content. Registration is FREE

kIDJOE is offline
Reply With Quote
View Public Profile Visit kIDJOE's homepage!
 
Old 07-06-2006, 03:46 PM Re: Two small problems in css
Skilled Talker

Posts: 92
Trades: 0
http://alistapart.com/articles/hybrid

No javascript. Straigh CSS.

Another example: http://www.cssplay.co.uk/menus/drop_down.html
__________________

Please login or register to view this content. Registration is FREE
Entertaining at least a few people every Monday night from 4-6 pm EST.

Last edited by waffles; 07-06-2006 at 05:46 PM..
waffles is offline
Reply With Quote
View Public Profile Visit waffles's homepage!
 
Old 07-06-2006, 05:55 PM Re: Two small problems in css
LadynRed's Avatar
Defies a Status

Posts: 10,016
Location: Tennessee
Trades: 0
Thanks Waffles.. ya beat me to it
__________________
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 07-06-2006, 08:45 PM Re: Two small problems in css
kIDJOE's Avatar
Extreme Talker

Posts: 186
Location: Hollywood, CA
Trades: 0
Not bad!
Even thogh your first example uses a JS fix and also, the second example wont ever run as smoth as the first example without JS.

Its OK to use Javascript.... A blend of good CSS with some javascript creates Dynamic HTML..

Familiar with the term DHTML ?
__________________

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
-
Please login or register to view this content. Registration is FREE


Last edited by kIDJOE; 07-06-2006 at 08:50 PM..
kIDJOE is offline
Reply With Quote
View Public Profile Visit kIDJOE's homepage!
 
Old 07-07-2006, 10:56 AM Re: Two small problems in css
LadynRed's Avatar
Defies a Status

Posts: 10,016
Location: Tennessee
Trades: 0
If you're going to use scripting it needs to be unobtrustive and accessible. If someone has JS turned off or are using assistive technology, then your page needs to display and work properly w/o JS.

CSS and Javascript does not = DHMTL
DHMTL is HTML + Javascript - hence the "HTML" designation
__________________
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 07-07-2006, 03:11 PM Re: Two small problems in css
kIDJOE's Avatar
Extreme Talker

Posts: 186
Location: Hollywood, CA
Trades: 0
I wonder how many people cannot actually run javascript. Thats is the one user IM not concerned about when implementing a cross-platform site, I care about must browsers, and versions and OS's but If they dont have JS turned on thats too much to code to. Thats my point of view.
__________________

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
-
Please login or register to view this content. Registration is FREE

kIDJOE is offline
Reply With Quote
View Public Profile Visit kIDJOE's homepage!
 
Old 07-07-2006, 05:08 PM Re: Two small problems in css
LadynRed's Avatar
Defies a Status

Posts: 10,016
Location: Tennessee
Trades: 0
Then you are completely alienating and ignoring anyone who uses assistive technology to surf the web. People with screen readers can't use javascript. If crucial features on a site ONLY work with JS (or Flash), then you're making it impossible for a certain sector of the web-surfing public to use the site. Accessibility is a big issue, lawsuits are flying, and we ALL need to stop pretending that anyone with a disability is a non-person and should not use the web or should just put up with a pathetic lack of support for them on the web.

Bottom line, if you're going to use JS, then make sure the site works WITHOUT it too.
__________________
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 07-07-2006, 05:15 PM Re: Two small problems in css
kIDJOE's Avatar
Extreme Talker

Posts: 186
Location: Hollywood, CA
Trades: 0
Quote:
...and ignoring anyone who uses assistive technology to surf the web
It depends on your targeted audience.

Quote:
...lawsuits are flying
What are you talking about??

I agree with cross-platform scripting. But there are certain things that wont work without javascript at all. and I dont think Google gmail has an alternate version without javascript.

Why are you so Hurt by javascript? why do you dislike it so bad? Remember! I agree with cross-platform websites....

I will change my signature to I love javascript...
__________________

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
-
Please login or register to view this content. Registration is FREE


Last edited by kIDJOE; 07-07-2006 at 05:17 PM..
kIDJOE is offline
Reply With Quote
View Public Profile Visit kIDJOE's homepage!
 
Old 07-07-2006, 08:23 PM Re: Two small problems in css
chrishirst's Avatar
Missing! presumed drunk.

Posts: 41,517
Name: Chris Hirst
Location: Blackpool. UK
Trades: 0
of course Gmail has a non JS version, just click the Basic HTML link below the messages.

You should try it for yourself, put yourself in the position of a disability aid user and disable javascript in your browser and then try surfing some sites.
If you want results from Search Engines, then some of the important visitors are js disabled, SE crawlers and indexers.
If your content relies on JS to make it available, it isn't going to be indexed.
__________________
Chris. ->> Links are advertising NOT optimising!! <<-
A foolish consistency is the hobgoblin of little minds
Thought for today:- I SEO the only industry where all the cowboys are Indians?
chrishirst is online now
Reply With Quote
View Public Profile Visit chrishirst's homepage!
 
Old 07-07-2006, 10:53 PM Re: Two small problems in css
kIDJOE's Avatar
Extreme Talker

Posts: 186
Location: Hollywood, CA
Trades: 0
You are right Gmail has a non JS version, thats awsome. Still, I love javascript.
__________________

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
-
Please login or register to view this content. Registration is FREE

kIDJOE is offline
Reply With Quote
View Public Profile Visit kIDJOE's homepage!
 
Reply     « Reply to Two small problems in css
 

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.54556 seconds with 12 queries