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.

Visited Links using graphics?

Featured Replies

Hi guys,

 

I'm building a web site for a client who insists on using a specific font for navigation purposes and he wants it to change colour when users have visited the link.

 

The font would not necessarily be installed on a viewers PC and I'm stumped.

 

I could make each link a .gif on a transparent background but it won't change colour once visited. I thought about having two .gifs for each link (one black, one grey) but don't know how to make it work.

 

I don't understand CSS and are using a package to design the web side as opposed to writing it all out long hand in HTML.

 

Does anyone know if there is a way to get over this problem?

 

Many thanks in anticipation

The popular "sliding doors" technique will do it nicely. You would still need a graphic for each link, but you would combine each 'state' so it's all in one image, so it only needs to be downloaded once. Essentially what happens is that you use the graphic as a background for an element with a fixed width and height, and move the position of the background image depending on the state. For instance, you could have your graphic split into four, with the 'normal' state in the top left of the image, 'hover' in top right, 'visited' in bottom left, and 'active' (i.e. being clicked) in bottom right. Then you would use some CSS a bit like this:

 

.menuitem {background: url(menuitem.gif) top left no-repeat; width: 100px; height: 40px;}
.menuitem:hover {background-position: top right;}
.menuitem:visited {background-position: bottom left;}
.menuitem:active {background-position: bottom right;}

 

Hope that helps! If not, I'm sure I did a tutorial on this once, I'll see if I can dig it out...

  • Author

Many thanks for the reply Matthew - much appreciated. I think I understand what you are saying but I don't think I know how to achieve this.

 

I've never used CSS so it might mean a trip to the bookstore to look for a copy of "An Idiots Guide to CSS"

 

I design 4 or 5 web sites and have always used a package so I've never learnt hot to manually program in HTML or CSS. If you could find your tutorial I think it would help enormously.

 

Kind regards

 

Baz

  • Author

I found THIS which would appear to be exactly what I need but I can't see where I get the code from?

Hi

 

if you are looking for a book to buy and don't want to spend a lot of money, try css mastery. http://www.cssmastery.com/

 

Shop around though as i am sure you'll pick it up for almost next to nothing. It teaches you the menu structures using unordered lists, the hover, active and visited techniques...

 

Also, this link may help you out CSS HERE

  • Author
Hi

 

if you are looking for a book to buy and don't want to spend a lot of money, try css mastery. http://www.cssmastery.com/

 

Shop around though as i am sure you'll pick it up for almost next to nothing. It teaches you the menu structures using unordered lists, the hover, active and visited techniques...

 

Also, this link may help you out CSS HERE

 

That should be a great help. Thank you.

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.