!!! %html{:lang => "fr", "xml:lang" => "fr", :xmlns => "http://www.w3.org/1999/xhtml"} %head %title=@title.to_s+" " %meta{ :"http-equiv" => "Content-Type", :content => "text/html; charset=utf-8" } %meta{ :"name" => "Description", :content => @description } %meta{ :"name" => "Keywords", :content => @keywords } = javascript_include_tag "public" = csrf_meta_tag = stylesheet_link_tag 'public' = stylesheet_link_tag '/fonts/Stylograph/stylesheet.css' =javascript_include_tag "http://maps.google.com/maps/api/js?sensor=false®ion=FR" %body -if flash[:error] or flash[:notice] or flash[:alert] .flash =flash[:error] =flash[:notice] =flash[:alert] -if !(@menu_item and @menu_item.slug and @menu_item.slug == "index" ) %p{:style => "height:80px;"} -if @menu_item and @menu_item.slug and @menu_item.slug == "index" #slider_content
=render :partial => "public/shared/top" -if !@no_sidebar #main #corps{:class => (@menu_item.slug if @menu_item)} -if @menu_item and @menu_item.slug and @menu_item.slug == "index" .main_section_title =link_to "Actualités +", "/actualites.html" -article = Article.where(:echo => false).before(Date.today).recents.first -if article %a{:href => public_article_path(:id => article.slug)} .first_article .image{:style => "background-image:url('"+(article.image_file.file.large.medium.url if article.image_file).to_s+"');"} .description %h1=article.title =simple_format article.description .clear -articles = Article.where(:echo => false).before(Date.today).recents.offset(1).limit(6) -if articles .articles -articles.each do |article| %a{:href => public_article_path(:id => article.slug)} .article .image{:style => "background-image:url('"+(article.image_file.file.large.medium.url if article.image_file).to_s+"');"} .description %h2=article.title .clear =yield #sidebar -if @menu_item and @menu_item.slug and @menu_item.slug == "index" .main_section_title =link_to "Prochainement +", "/agenda.html" -@side_events = Event.where(' (start_at > ?) or (stop_at > ?)',Time.now,Time.now).order(:start_at).limit(5) =render :partial => "public/events/event_mini", :collection => @side_events, :as => :event =yield :sidebar .clear -else #main =yield .bottom =link_to image_tag("/nb.png"), "http://nicolasbally.com", :target => "_blank"