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 CSS: Cascading Style Sheets Take a Mobile-First Approach

Can I use a jpeg image instead of text for the logo?

I'm trying to use a jpg image as a logo instead of text. Using the #logo selector, how would I write the css to center, add margins etc..?

3 Answers

Steven Parker
Steven Parker
231,275 Points

Give the course a chance.

If you keep going, your course will shortly show you how to build an image gallery. I'd bet most of what you want to know about image styling will be covered there.

My suggestion is keep going, and if everything you want to know hasn't been covered by the end, ask again.

Kit Navock
Kit Navock
4,540 Points

Yeah, don't get too bogged down by trying to make everything like you want it right now. As Steven said, it'll come.

But yes, you can. I'm not sure what less you're on, but if you're on the one I think you're one, you just have to stick the image between the <a> tags and swap out the <h1> and <p> tags.

straight answer ==> yes . since some devices can't support jpeg etc and they need to get prepared or resized, people use mostly png for education purposes, bcoz they are easy and most devices recognise this type of file ...