Tycoon Talk
Become a Big fish!
The number 1 forum for online business!
Post topics, ask questions, share your knowledge.
Tycoon Talk is part of Freelancer.com - find skilled workers online at a fraction of the cost.

HTML Forum


You are currently viewing our HTML Forum as a guest. Please register to participate.
Login



Post a Project »

Find a Professional HTML Freelancer!

Find a Freelancer to help you with your HTML projects

FREE Outsourcing eBook!

Reply
Relatives Links... Is it possible?
Old 08-02-2010, 06:05 PM Relatives Links... Is it possible?
Banned

Posts: 39
Trades: 0
I have searched all over to find a solution to this issue.

Let's say that I am on this page: http://www.site.com/folder1/folder1/...der4/file.html

I want to be able to link to http://www.site.com/other-fold/

I have tried entering the following code but it just takes be up one level:
<a href="../other-fold">link</a>

Does anyone know what I need to enter instead of .. ? What should the code be?

Remember, I want to do this using relative links (not absolute).

Please and thank you
CyberWizard is offline
Reply With Quote
View Public Profile
 
 
Register now for full access!
Old 08-02-2010, 06:08 PM Re: Relatives Links... Is it possible?
chrishirst's Avatar
Missing! presumed drunk.

Posts: 42,380
Name: Chris Hirst
Location: Blackpool. UK
Trades: 0
http://www.communitymx.com/content/a....cfm?cid=230ad
__________________
Chris. ->>
Please login or register to view this content. Registration is FREE
<<-

A foolish consistency is the hobgoblin of little minds
Thought for today:- Is SEO the only industry where all the cowboys are Indians?
chrishirst is offline
Reply With Quote
View Public Profile Visit chrishirst's homepage!
 
Old 08-02-2010, 06:34 PM Re: Relatives Links... Is it possible?
Banned

Posts: 39
Trades: 0
Is it possible for it to make it find the route directory without having to specify exactly how many levels to go up?
CyberWizard is offline
Reply With Quote
View Public Profile
 
Old 08-02-2010, 06:59 PM Re: Relatives Links... Is it possible?
chrishirst's Avatar
Missing! presumed drunk.

Posts: 42,380
Name: Chris Hirst
Location: Blackpool. UK
Trades: 0
start the path with a "/" to signify the root.

/folder/folder/folder/file.ext
__________________
Chris. ->>
Please login or register to view this content. Registration is FREE
<<-

A foolish consistency is the hobgoblin of little minds
Thought for today:- Is SEO the only industry where all the cowboys are Indians?
chrishirst is offline
Reply With Quote
View Public Profile Visit chrishirst's homepage!
 
Old 08-02-2010, 07:43 PM Re: Relatives Links... Is it possible?
Banned

Posts: 39
Trades: 0
I am doing that.

Here is the page the link is in: http://www.site.com/folder/page.html

And here is the link:

<a href="/folder1/folder2/">link</a>

But when I click on that link it is trying to take me to this page:
http://www.site.com/folder/page.html/folder1/folder/2/
CyberWizard is offline
Reply With Quote
View Public Profile
 
Old 08-02-2010, 07:58 PM Re: Relatives Links... Is it possible?
chrishirst's Avatar
Missing! presumed drunk.

Posts: 42,380
Name: Chris Hirst
Location: Blackpool. UK
Trades: 0
To set a path of www site.com/folder/page.html/folder1/folder/2/

the slash MUST not be on the href of folder1/folder/2/


Without the "/" on the href, the path will be normalised as document relative, and the href attribute will be appended to the current path.
__________________
Chris. ->>
Please login or register to view this content. Registration is FREE
<<-

A foolish consistency is the hobgoblin of little minds
Thought for today:- Is SEO the only industry where all the cowboys are Indians?
chrishirst is offline
Reply With Quote
View Public Profile Visit chrishirst's homepage!
 
Old 08-05-2010, 01:40 AM Re: Relatives Links... Is it possible?
Novice Talker

Posts: 2
Name: Stifan March
Trades: 0
If you put absolute links in and then move the code to some other location on the same server then you have to do less rework. However, if you move the code to an entirely different site then your site might work right away while both sites are up and running, but eventually the old site will go away and the images will no longer appear unless you manage to change you code when you move to another site. It is generally best to use relative paths in a business environment because you might not being doing the updates to that code in the future, and using absolute paths is not the standard HTML development approach.
__________________

Please login or register to view this content. Registration is FREE
|
Please login or register to view this content. Registration is FREE
|
Please login or register to view this content. Registration is FREE
Stifan March is offline
Reply With Quote
View Public Profile
 
Reply     « Reply to Relatives Links... Is it possible?
 

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off





   
RSS Feed  Feeds: RSS   JS   XML
RSS Feed  Feeds for this forum: RSS   JS   XML



Page generated in 2.43599 seconds with 12 queries