ecole_eft_app/app/views/layouts/public.html.haml
2017-04-16 23:23:23 +02:00

118 lines
3.6 KiB
Plaintext
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

!!!
%html{:xmlns=>"http://www.w3.org/1999/xhtml", :"xml:lang"=>"fr", :lang=>"fr"}
%head
- @title = @title || "Formations EFT de Geneviève Gagos de lEcole EFT France"
- @description = @description || "Lécole EFT France vous assure une formation EFT recommandée par Gary Craig et conforme à sa norme dexcellence."
%title= @title.to_s+" | Ecole-eft-france.fr"
%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'
=render :partial => "public/shared/ga"
=javascript_include_tag "https://maps.google.com/maps/api/js?sensor=false&region=FR"
%body
%a{:id => "top_anchor"}
#large.container
#top
=link_to image_tag( "front/logo.png", :id => "logo", :alt => ""), "/"
%ul#menu
%li=link_to i(:home, :icon => false), "/"
=render(:partial => "public/shared/first_menu")
#main.row
.col-md-8
=yield
.col-md-4.sidebar
=yield :sidebar
#testimony_slideshow
-Testimony.find(:all).sort_by { rand }.each do |testimony|
.testimony
.quote
=image_tag("front/left.png", :class => "prev-testimony")
=link_to testimony.quote, testimony_path(:slug => testimony.id.to_s+"-"+testimony.author.to_slug)
=image_tag("front/right.png", :class => "next-testimony")
.author=link_to testimony.author, testimony_path(:slug => testimony.id.to_s+"-"+testimony.author.to_slug)
%br
%br
%div{:style => "text-align:right;"}=link_to "Tous les témoignages", testimonies_path
:coffeescript
stop_dia = false
next_testimony = ->
active = $("#testimony_slideshow .active:first")
if active.next(".testimony").length == 0
$("#testimony_slideshow").append($("#testimony_slideshow").children(".testimony:first"))
active.fadeOut(300).removeClass("active")
active.next(".testimony").delay(300).fadeIn(300).addClass("active")
$(".prev-testimony").click ->
stop_dia = true
active = $("#testimony_slideshow .active:first")
if active.prev(".testimony").length == 0
$("#testimony_slideshow").prepend($("#testimony_slideshow").children(".testimony:last"))
active.fadeOut(300).removeClass("active")
active.prev(".testimony").delay(300).fadeIn(300).addClass("active")
$(".next-testimony").click ->
stop_dia = true
next_testimony()
dia_testimony = ->
if stop_dia == false
next_testimony()
window.setTimeout (->
dia_testimony()
), 7000
dia_testimony()
$("#testimony_slideshow").children(".testimony:first").show().addClass("active")
#bottom
%a#go_top{:href => "#top_anchor"}