<!doctype html>
<html xmlns:fb="http://www.facebook.com/2008/fbml">
  <head>
    <title>Muzi.ch - {% block title %}{% endblock %}</title>
    {% include 'MuzichCoreBundle:Layout:head.html.twig' %}
    {% block css %}{% endblock %}
    {% block js %}{% endblock %}
  </head>
  <body>
    
    {% if  app.environment == 'prod' %}
      {% include 'MuzichCoreBundle:Component:facebook.html.twig' %}
    {% endif %}
    {% include 'MuzichCoreBundle:Layout:noscript.html.twig' %}
    {% include 'MuzichCoreBundle:Autoplay:autoplay.html.twig' %}
  
  <div id="container">
    
    {% if app.user %}
      <a style="display: none;" onmouseover="UE.Popin.preload();" href="#" onclick="UE.Popin.show(); return false;">Vos retours</a>
    {% endif %}
  
    <div id="main_content">
      
      <div id="header">
        {% include 'MuzichCoreBundle:Layout:header.html.twig' %}
      </div>
      
      {% include 'MuzichCoreBundle:Layout:flash_messages.html.twig' %}
      
      <div id="content">
        
        <div id="main" class="content">
          
          <div id="mainbox" class="nicebox {% block mainbox_classes %}{% endblock %}">
            {% block main_content %}{% endblock %}
            {% block fos_user_content %}{% endblock %}
          </div>
          
        </div>
          
        <aside id="sidebar">
          <div class="sidebar">
            {% block sidebar_top %}{% endblock %}
            {% include 'MuzichCoreBundle:Layout:side.html.twig' %}
            {% block sidebar_bottom %}{% endblock %}
          </div>
        </aside>
          
      </div>
      
    </div>
    
    <div id="footer">
      {% include 'MuzichCoreBundle:Layout:footer.html.twig' %}
    </div>
    
  </div>
    
    {% if  app.environment == 'prod' %} 
      <!-- Piwik -->
      <script type="text/javascript"> 
        var _paq = _paq || [];
        _paq.push(['trackPageView']);
        _paq.push(['enableLinkTracking']);
        (function() {
          //var u=(("https:" == document.location.protocol) ? "https" : "http") + "://analytics.muzi.ch//"; # pas de certif sur analytics.muzi.ch pour le moment
          var u=(("https:" == document.location.protocol) ? "http" : "http") + "://analytics.muzi.ch//";
          _paq.push(['setTrackerUrl', u+'piwik.php']);
          _paq.push(['setSiteId', 1]);
          var d=document, g=d.createElement('script'), s=d.getElementsByTagName('script')[0]; g.type='text/javascript';
          g.defer=true; g.async=true; g.src=u+'piwik.js'; s.parentNode.insertBefore(g,s);
        })();
      
      </script>
      <noscript><p><img src="http://analytics.muzi.ch/piwik.php?idsite=1" style="border:0" alt="" /></p></noscript>
      <!-- End Piwik Code -->
    {% endif %}
  </body>
</html>
