| | |
Unordered Lists
Please support our HTML and CSS advertiser: PostgreSQL or MySQL? Compare and contrast the two most popular open source databases
![]() |
Is there a way to make links in unordered lists be non-underlined by default? And when the user hovers over the link, it becomes underlined?
Here's the current code:
On the page with the lists, all of the links are underlined by default and the underline goes away when you hover over it. We want the opposite of this.
Here's the current code:
HTML and CSS Syntax (Toggle Plain Text)
<ul> <li><a href="water">Water</a></li> <li><a href="wastewater">Wastewater</a></li> <li><a href="surveying">Surveying</a></li> <li><a href="aerial">Aerial</a></li> <li><a href="it">Technology Consulting</a></li> </ul>
On the page with the lists, all of the links are underlined by default and the underline goes away when you hover over it. We want the opposite of this.
It is practically impossible to teach good programming style to students that have had prior exposure to Basic; as potential programmers they are mentally mutilated beyond hope of regeneration.
-Edsger Dijkstra
-Edsger Dijkstra
•
•
Join Date: Aug 2009
Posts: 15
Reputation:
Solved Threads: 0
Duki,
I have listed two cases for the hovers. use what you really need off
case 1:
case 2:
Regards
chavansoft
I have listed two cases for the hovers. use what you really need off
case 1:
HTML and CSS Syntax (Toggle Plain Text)
<style> #hover li a { text-decoration:underline; } #hover li a:hover { text-decoration:none; } </style> <ul id="hover"> <li><a href="water">Water</a></li> <li><a href="wastewater">Wastewater</a></li> <li><a href="surveying">Surveying</a></li> <li><a href="aerial">Aerial</a></li> <li><a href="it">Technology Consulting</a></li> </ul>
case 2:
HTML and CSS Syntax (Toggle Plain Text)
<style> #hover li a { text-decoration:none; } #hover li a:hover { text-decoration:underline; } </style> <ul id="hover"> <li><a href="water">Water</a></li> <li><a href="wastewater">Wastewater</a></li> <li><a href="surveying">Surveying</a></li> <li><a href="aerial">Aerial</a></li> <li><a href="it">Technology Consulting</a></li> </ul>
Regards
chavansoft
You can also do a reset and have all ul not be underlined and only create a class for a list you want to underline.
HTML and CSS Syntax (Toggle Plain Text)
<style> ul li { text-decoration : none; } </style>
Last edited by AdrianaTX; Sep 2nd, 2009 at 3:30 pm.
In Texas ya'll
![]() |
Similar Threads
- List list list (HTML and CSS)
- Help with 2-Tier Navigation (PHP)
- IMG problem in IE7 (PHP)
- Creating HTML structure using lists (HTML and CSS)
- The most famous CSS web sites galleries in the world (HTML and CSS)
- School Teacher needs help with website (HTML and CSS)
- Problem with lists in advanced reply (DaniWeb Community Feedback)
- Easy drop down menu? (JavaScript / DHTML / AJAX)
- IE and strange UL-tag Phenomena (HTML and CSS)
Other Threads in the HTML and CSS Forum
- Previous Thread: Good web page designer for Linux
- Next Thread: image slideshow..
| Thread Tools | Search this Thread |
appointments asp background backgroundcolor beta browser bug calendar cart cgi code codeinjection corporateidentity css design development displayimageinsteadofflash dreamweaver emailmarketing epilepsy explorer firefox flash form format google griefers hackers hitcounter hover html ide ie7 ie8 iframe image images internet internetexplorer intranet iphone javascript jpeg layout macbook maps marketshare microsoft mozilla multimedia navigationbars news offshoreoutsourcingcompany opacity opera optimization pnginie6 positioning problem scroll seo shopping studio swf swf. textcolor timecolor titletags url urlseparatedwords visual visualization web webdevelopment webform website windows7






