Ashish Gupta
Ashish Gupta

Reputation: 185

In url("../(folder-name)/(image-name)"), what does "../" represent?

background-image: url("../images/intro-1.jpg");

In the above piece of CSS code, I am having trouble figuring out why that .. is used.

Upvotes: 0

Views: 35

Answers (1)

Himanshu Bansal
Himanshu Bansal

Reputation: 2093

This is used to get out of current or access parent directory:

  • ./ means current directory
  • ../ means parent directory

Have a look at Paths explained: Absolute, relative, UNC, and URL.

Upvotes: 2

Related Questions