What’s the difference between ./dogs.html and /dogs.html?

They are both URL paths. They have different names, though.

<a href=”./dogs.html">Dogs</a>
<!– absolute –>
<a href="/dogs.html">Dogs</a>
There are also fully-qualified URLs that would be like:
<!– fully qualified –>
<a href="https://website.com/dogs.html">Dogs</a>
Fully-qualified URL’s are pretty obvious in what they do — that link takes you to that exact place. So, let’s look those first two examples again.
Say you have a directory structure like this on your site:
public/
├── index.html
└── animals/
├── cats.html

The post What’s the difference between ./dogs.html and /dogs.html? appeared first on CSS-Tricks.

Link: https://css-tricks.com/whats-the-difference-between-dogs-html-and-dogs-html/