View Full Version : Newbe needs help

02-17-2008, 09:18 AM
I am a newbe and I have 2 problems.

First, I have this code in my GettingStarted.html

<a style="CURSOR: crosshair" href="GettingStarted2.html" >NEXT</a>

When I click it in my Browser, I get the error Page "This program cannot display the webpage". Both GettingStarted.html and GettingStarted2.html are in the same directory. I know my browser is working because the identical href code works in another site. I got the sourse code from that and copy pasted it into my code with just the destination changed and it doesn't work in my code. Could there be come code before this code that is screwing it up?

Can anyone suggest why this is so? I don't believe the code is wrong, but would love to find out that it is!

The second problem I have is that I do not want any change in the color of the text when I click on it and come back to the page. I want the text to stay black no matter how it is clicked.

I have tried adding css style to the code

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<style type="text/css">
:link { text-decoration: none color: rgb(0, 0, 0) } /* for unvisited links */
:visited { text-decoration: none color: rgb(0, 0, 0) } /* for visited links */
:hover { text-decoration: none color: rgb(0, 0, 0) } /* when mouse is over link */
:active { text-decoration: none color: rgb(0, 0, 0) } /* when link is clicked */

but it seems to make no difference. Is there some thing wrong with the css code? I copied and paster it right from a css tutor manual. Is there any other way to stop the text from changing color in a link?

I would really appreciate some help!
Dick Roose

02-17-2008, 11:17 AM
First, give a meaningful title to your post. See the posting guidelines near the top of this page.

As far as I can see the first of your snippets works OK for me.

The second problem is a simple syntax error. You need a semicolon after 'none' in your style.
a:link { text-decoration: none; color: rgb(0, 0, 0) } /* for unvisited links */ Note that it is desirable to use the a:link rather than the bare :link. This focusses your mind on the fact that, for IE6, these behaviours will only work within anchors.


02-17-2008, 09:32 PM
as far as the style on the link, try this:

<a href="GettingStarted2.html" style="cursor:crosshair;" >NEXT</a>

im not sure but i believe the href needs to follow the a, although i might be wrong, also its best to close the style like a basic css file would be with an ;.

02-18-2008, 12:58 PM
Have you tried directly accessing GettingStarted2.html in your browser? If you can't, it's obviously not there.