Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

CSS

Background-image: url attribute

just wanted to know what do we need to type within the brackets in the url tab

Background-image: url(' ');

given that my image is on the desktop.

thanks in advance

1 Answer

Hello mate!

The best way to do this, if you're using a Windows OS. Right click on the image(on Desktop as you have said) and select Properties in the options. After that you'll be able to see the location of your image, then copy the path and paste it to your code. (don't forget to add your image name).

like so.

Background-image: url('C:\Users\YourPCNAME\Desktop\yourimage.jpeg');

Cheers!

thanks man i found my mistake i added some dots before the url