alt text mods

This commit is contained in:
Harry Bomrah 2015-05-11 18:19:57 +08:00
parent 921c8addd4
commit a31d5d24cd
1 changed files with 4 additions and 2 deletions

View File

@ -5,7 +5,8 @@ class AdBannersController < ApplicationController
image_link = OrbitHelper.is_mobile_view ? b.file.mobile.url : b.file.url
klass = i == 0 ? "active" : ""
caption = i == 0 ? '<div class="cycle-overlay"></div><div class="cycle-pager"></div>' : ""
title = (b.title.nil? || b.title == "" ? "ad-banner image" : b.title)
alt_title = (b.title.nil? || b.title == "" ? "ad-banner image" : b.title)
if b.link_open == "new_window"
target = "_blank"
else
@ -15,7 +16,8 @@ class AdBannersController < ApplicationController
{
"image_link" => image_link,
"image_alt" => "ad banner image",
"title" => title,
"title" => b.title,
"alt_title" => alt_title,
"class" => klass,
"height" => adbanner.height,
"width" => adbanner.width,