Class: ODDB::Html::View::Head
- Inherits:
-
HtmlGrid::DivComposite
- Object
- HtmlGrid::DivComposite
- ODDB::Html::View::Head
- Defined in:
- lib/oddb/html/view/head.rb
Direct Known Subclasses
Constant Summary collapse
- COMPONENTS =
{ [0,0] => :user, [0,1] => :google_ads, [0,2] => :logo, }
- CSS_ID_MAP =
["user", "google-ads"]
Instance Method Summary collapse
Instance Method Details
#google_ads(model) ⇒ Object
20 21 22 23 24 |
# File 'lib/oddb/html/view/head.rb', line 20 def google_ads(model) if(@lookandfeel.enabled?(:google_ads) && !@session.logged_in?) GoogleAds.new :width => 468, :height => 60, :channel => '6336403681' end end |
#logo(model) ⇒ Object
25 26 27 28 29 30 31 32 33 34 35 36 37 |
# File 'lib/oddb/html/view/head.rb', line 25 def logo(model) return if @lookandfeel.disabled? :logo target = :home logo = HtmlGrid::Image.new(:logo, model, @session, self) if(@session.direct_event == target) logo else link = HtmlGrid::Link.new(target, model, @session, self) link.value = logo link.href = @lookandfeel._event_url(target) link end end |