HTML & WEB-Design

Moderators: Jonathan
Number of threads: 1249
Number of posts: 3348

This Forum Only
Post New Thread
Single Post View       Linear View       Threaded View      f

Report
How do I do an intralink ? Posted by luffy28 on 19 Jan 2009 at 3:11 PM
A link to another part of the website you're building. Like a different page ?
Report
Re: How do I do an intralink ? Posted by CyGuy on 23 Jan 2009 at 10:56 PM
There are a couple of ways to accomplish the task:

if you are familiar with adding events to html elements here is the same folder link:
onClick="parent.location='file.ext'"

otherwise surround the link text with an anchor tag
<a href="file.ext">link</a>


The above assumes that the file you link to is in the same folder/directory as the folder you link from...

should the file you link to be in the parent folder containing the folder you would click to get to the file you linked from you can replace file.ext with ../file.ext

should the file you link to be in the child folder that appears in the folder with the file you linked from you must specify the folder name file.ext with ./folderfile.ext The more you drill down by clicking folders the longer the link
./folder/file.ext with ./folder1/folder2/onDown/folder/file.ext

The ./ before the link means starting from the current default location on the system, hosted or otherwise. On your computer that is usually the folder of the file, but on a website it can be configured as anything. The default folder that is usually the one you would start in is also typically specified in the address bar as symply the filename after the .com or domain name thing, so if your original file file.ext is the default... there are a few ways to access it using the html code above by linking within that folder:
file.ext
./file.ext
www.yoursite.com/file.ext

I have seen templates that refer to folders that aren't accessible by using the ../ folder above reference like ../../../wow/overyourhead.html three folders above the default folder and in wow folder is overyourhead

Config files allow more rubust access features, but the above are the basics



 

Recent Jobs

Official Programmer's Heaven Blogs
Web Hosting | Browser and Social Games | Gadgets

Popular resources on Programmersheaven.com
Assembly | Basic | C | C# | C++ | Delphi | Flash | Java | JavaScript | Pascal | Perl | PHP | Python | Ruby | Visual Basic
© Copyright 2011 Programmersheaven.com - All rights reserved.
Reproduction in whole or in part, in any form or medium without express written permission is prohibited.
Violators of this policy may be subject to legal action. Please read our Terms Of Use and Privacy Statement for more information.
Operated by CommunityHeaven, a BootstrapLabs company.