htmlurlhyperlinkanchorrelative-url

Relative URL to a sub-directory in HTML


Can we create a relative link in HTML? For example, how can I write a relative URL on this page

http://www.example.com/dir/sub-dir

to this sub page

http://www.example.com/dir/sub-dir/sub-sub-dir

Is this even possible in HTML?


Solution

  • Well.... just write it relative:

    <a href="sub-sub-dir">Text</a>