This commit is contained in:
邱博亞 2021-04-10 17:13:57 +08:00
parent 70d52cb924
commit 4bee341acc
1 changed files with 1 additions and 1 deletions

View File

@ -71,7 +71,7 @@ class AdBannersController < ApplicationController
image_html = "<div class='w-ad-banner__slide #{klass}' data-link='#{ad_b.out_link || "#"}''><img class='w-ad-banner__image' src='#{image_link}'><div class='w-ad-banner__caption_text'>#{ad_b.title}</div></div>"
else ad_b.exchange_item == "2"
youtube_url = format_url(ad_b.youtube,i)
image_html = "<div class='w-ad-banner__slide youtube #{klass}' data-yt-binded='0' data-youtube-id='ytplayer#{i}'><div style=\"padding-bottom: 56.25%;position: relative;height: 0;\"><iframe height=\"100%\" width=\"100%\" src=\"#{youtube_url}\" title=\"youtube\" style=\"position: absolute;\"></iframe></div><a class='w-ad-banner__slide' href='#{youtube_url}'>#{ad_b.title}</a><div class='w-ad-banner__caption_text'>#{ad_b.title}</div></div>"
image_html = "<div class='w-ad-banner__slide youtube #{klass}' data-yt-binded='0' data-youtube-id='ytplayer#{i}'><div style=\"padding-bottom: 56.25%;position: relative;height: 0;\"><iframe height=\"100%\" width=\"100%\" src=\"#{youtube_url}\" title=\"youtube\" style=\"position: absolute;\"></iframe></div><div class='w-ad-banner__caption_text'>#{ad_b.title}</div></div>"
end
images << {
"html" => image_html