HTML question Regarding <a href?

walter james g

New member
We are supposed to create a webpage for class. We are then to recreate the same page in subdirectories so that that the original page links to the pages in the subdirectories. I got the "Local" Link working but none of my other Links will work and all of the files are in the same subdirectory. The code for the "a href" <td><table width="100%" border="0" cellpadding="0" cellspacing="0">
<tr>
<td width="10">&nbsp</td>
<td><a href="pages/news/local.html">Local</a></td>
</tr>
<tr>
<td width="10">&nbsp</td>
<td><a href="pages/news/state.html">State</a></td>
</tr>
<tr>
<td width="10">&nbsp</td>
<td><a href="pages/news/national.html">National</a></td>
</tr> and so on . The Local Link is working, all the links after that will not and I cannot figure out why they aren't. Any ideas would be greatly appreciated. This is supposed to be intro to HTML and is week five, I'm thinking the instructor is a little psychotic. That was a SMALL portion of the assignment. Help!
 
If you copy the links to the pages in subfolders, then go to loacl.html and try to go to State from Locale then it will not work because you are already in pages/news.

The best way you can do is to put it in the following way href="/yoursitename/pages/news/pagename" for all yoour links in all the pages. This will start looking from the root of you website instead of the current path
 
Back
Top