XF 1.4 How to add post attachment image as post background via css

I'm looking into how I might add an attachment where the attachment is the first attachment and is an image as the background for the post.

So the steps would be:

1. Create post.

2. Upload attachment.

3. CSS uses the attachment url as the background for the first post.

I wouldn't need any kind of if conditionals because I would be the only one with this kind of ability on the forum. Users can't upload attachments.

I'd actually be using this for Xenporta 2, but the css used would be the same for posts and I think keeping it to that for the purposes of comments would be easier on anyone giving advice.

Basically as I see it I would need to know how what code to use for the css background: pram.

Closest snippet I got was {$article.article_icon.data.thumbnailUrl} from Xenporta 2. I wanted to get opinions before I tried anything though. Also I want the full image not the thumb.
 
Top Bottom