Q1. What is a file path in HTML?
A file path describes the location of a file in a website's folder structure, used in src, href, and other attributes.
Q2. What is the difference between absolute and relative file paths?
Absolute paths specify full URL (https://example.com/images/pic.jpg). Relative paths point within current site (images/pic.jpg or ../images/pic.jpg).
Q3. What does ../ mean in a file path?
../ means go up one directory level from the current folder. Use multiple ../ to go up multiple levels.
Q4. What is the root directory in web development?
The root directory is the top-level folder of your website. A forward slash (/) at path start refers to the root.
Q5. Why are relative paths preferred over absolute paths?
Relative paths make your website portable - they work on any domain without changing links, essential for local development.
