<% if image.exchange_item == '1' %>
" style="background: url('<%= image.file.thumb.url %>'); background-size: cover; background-position: center;">
<% if image.expired? %>
<%= t("ad_banner.expired") %>
<% end %>
<% if (image.postdate > Time.now rescue false) %>
<%= t("start_date")+': '+(format_value image.postdate) %>
<% end %>
<%= t('image') %>
<%= t(:edit) %>
<%= t(:delete_) %>
<% else %>
" style="background: url('http://img.youtube.com/vi/<%= image.youtube.to_s[-11,11] %>/hqdefault.jpg'); background-size: cover; background-position: center;">
<% if image.expired? %>
<%= t("ad_banner.expired") %>
<% end %>
<% if (image.postdate > Time.now rescue false) %>
<%= t("start_date")+': '+(format_value image.postdate) %>
<% end %>
<%= t('video') %>
<%= t(:edit) %>
<%= t(:delete_) %>
<% end %>
<%= t("title") %> : |
<%= image.title %> |
<%= t("start_date") %> : |
<%= format_value image.postdate %> |
<%= t("end_date") %> : |
<%= format_value image.deadline %> |
<%= t("link") %> : |
<%= image.out_link rescue " " %> |