How do print term image field as background style attribute in views-view.tpl.php? How do print term image field as background style attribute in views-view.tpl.php or in views-view-unformatted.tpl.php file?
I have view which lists terms of taxonomy vocabulary. All terms have title and image fields. I need to lists terms like:

&lt;div style="background-image:url(http://example.com/term1_field_image.jpg);"&gt;
&lt;h2&gt;Title&lt;/h2&gt;
&lt;div&gt;
&lt;div style="background-image:url(http://example.com/term2_field_image.jpg);"&gt;
&lt;h2&gt;Title&lt;/h2&gt;
&lt;div&gt;
You can achieve this with row style instead. Go to your views advance settings then click on theming information and look for appropriate name for row styling and write something like this.

$uriImagefromView = $row-&gt;field_field_image[0]['rendered']['#item']['uri'];
$urlImagefromView = file_create_url($uriImagefromView);


This will give you the url to the path of that image. Now you can easily render it as background.

If you want to render your background image in particular size you created in image style you can do like this

$resized_url = image_style_url('&lt;style_name&gt;', $uriImagefromView);