Forum

Thread tagged as: Question, Blog

Blog Post Image as CSS Background Image

Hi,

I've done this many times before and for some reason on this occasion I cannot get an image inserted by Perch to show up as my background image. I need a second pair of eyes. Here's my code:

<div class="post-hero" style="background-image: url(<perch:blog type="image" id="image" label="Image"/>);"></div>

Thoughts? Thanks ahead of time!

Greg Stone

Greg Stone 0 points

  • 4 years ago
Rachel Andrew

Rachel Andrew 394 points
Perch Support

If you view source can you see the image in your source?

No, actually... it's blank. I imagine I need to change the path of something somewhere...

Rachel Andrew

Rachel Andrew 394 points
Perch Support

I'm going to need more information to be able to help.