views:

468

answers:

1

I would like to use javascript to style an element to look like a :visited link, without defining my own styles for visited links. How can I access the browser's default style for visited links, so that I can define a matching style that I can apply to an element (e.g. by applying a class name)?

A: 

You could try opening the page in hidden <iframe />. I don't see another solution besides building extensions for the browser(s) to do what you want to do. I also don't know if you are putting too much effort into it.

It could be as simple as establishing some rules for your app.

For example, new link vs. visited link. The differences are obvious and don't depend on color either.

Till