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

HTML How to Make a Website Adding Pages to a Website Add Iconography

Marissa Berrong - Van Wey
Marissa Berrong - Van Wey
5,576 Points

Icons will not appear

I'm not sure what I'm doing wrong, but I can't get the phone and mail icon to work on my contact page (I don't use Twitter, so I left it out). Can someone help?

.contact-info li.phone a{ background-image: url("..Img/phone.png");}

.contact-info li.mail a{ background-image: url("..Img/mail.png");}

Snapshot: https://w.trhou.se/5vyjvhmu0k

4 Answers

Pedro Sousa
seal-mask
.a{fill-rule:evenodd;}techdegree
Pedro Sousa
Python Development Techdegree Student 18,546 Points

Hallo Marissa!

Your image paths are not valid.

You can use "../" to back one directory. Your missing the slash before "Img".

This should work.

.contact-info li.phone a{ background-image: url("../Img/phone.png");}

.contact-info li.mail a{ background-image: url("../Img/mail.png");}
Pedro Sousa
seal-mask
.a{fill-rule:evenodd;}techdegree
Pedro Sousa
Python Development Techdegree Student 18,546 Points

I'm glad I could help :)

In case you didn't quite understand the file paths and why they really worked, when/if you feel ready, maybe you can check out the Console Foundations -> Getting Started with the Console -> Moving Around the File System (it's a bit trickier, but its worth it :P) .

Keep up the good learning!

Marissa Berrong - Van Wey
Marissa Berrong - Van Wey
5,576 Points

I fixed the image paths as you wrote, and they work! Thanks so much Pedro!!

Marissa Berrong - Van Wey
Marissa Berrong - Van Wey
5,576 Points

I will definitely check that out! I could use more study on the file paths and their functions.

Thank you, take care!