# Bug in Set Style Property when property is background or background-image

**URL:** <https://forum.pinegrow.com/t/bug-in-set-style-property-when-property-is-background-or-background-image/80>\
**Category:** Pinegrow WP\
**Created:** [July 31, 2016, 9:10pm UTC](https://forum.pinegrow.com/t/bug-in-set-style-property-when-property-is-background-or-background-image/80 "2016-07-31T21:10:35Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![itsmeleo](https://yyz2.discourse-cdn.com/flex036/user_avatar/forum.pinegrow.com/itsmeleo/32/19_2.png) [@itsmeleo](https://forum.pinegrow.com/u/itsmeleo)\
**Post date:** [July 31, 2016, 9:10pm UTC](https://forum.pinegrow.com/t/bug-in-set-style-property-when-property-is-background-or-background-image/80/1 "2016-07-31T21:10:35Z")

</div>

There is a bug in PG when adding a php code in any element and select style property and type the image url it doesn’t add it like this

background-image: url(path);  
background: url(path);  
it adds it like this

background-image: path;  
background:path;

 ![](https://canada1.discourse-cdn.com/flex036/uploads/pinegrow/original/1X/9fdded3422444625e487eb51311417c370f09a90.png)

so this is bug in PG WP kindly check it and make a future update fix for it.

---

<div class="post-metadata">

**Author:** ![matjaz](https://yyz2.discourse-cdn.com/flex036/user_avatar/forum.pinegrow.com/matjaz/32/5_2.png) [@matjaz](https://forum.pinegrow.com/u/matjaz)\
**Post date:** [August 15, 2016, 9:09am UTC](https://forum.pinegrow.com/t/bug-in-set-style-property-when-property-is-background-or-background-image/80/2 "2016-08-15T09:09:19Z")

</div>

It’s not really a bug. PG doesn’t know what the PHP code will output - will url() be included in that or not.

Let’s say you want to set $image\_url to the `background` property. Then set the code to `'url(\''.$image_url.'\')'`
