Skip to content
View in the app

A better way to browse. Learn more.

Web Designer Forum

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Question: Navigation CSS options

Featured Replies

Another question from me,

What's the CSS code for a navigation class item to have let's say a different font color when it is the current page item. I guess it should be something like:

#navigation a.somethinghere {
color: #desired color;
background: #desired bgcolor;
}

 

What should i put instead of "somethinghere"? Thanks :)

It depends completey on where your putting the "<a href="...."></a>"

 

typically, you would have the following in you source code:

 

<p class="john">
  this is my text but ooo heres a link <a href="newpage.htm">I'm a link</a>
</p>

 

For this link color to change you would have the following CSS...

 

.john a {color: #000000;} // this is just the generic link color...
.john a:visited {color: #444444;} // this would be the color of the link once visited
.john a:hover {color: #aaaaaa;} // this is the link color when you hover over it.

 

It's very important to put these in the wrong order. If you put 'a' by itself at the end of the css code, it would 'overide' the colors you set for the others.

 

If you don't want a different 'visited' color, just don't include it, as long as you have stated the color for 'a' by itself (The top property here) it will become BLACK (#000000} in my case...

 

I hope this helps...

It's very important to put these in the wrong order.

 

Don't you mean 'not to put these in the wrong order'. Here is a good page explaining about links:

 

CSS LINKS

Create an account or sign in to comment

Account

Navigation

Search

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.