templates/front/base.html.twig line 1

Open in your IDE?
  1. <!DOCTYPE html>
  2. <html lang="{{ app.request.locale }}">
  3.     <head>
  4.         {% if app.request.server.get('SERVER_ENV') and app.request.server.get('SERVER_ENV') == 'production' %}
  5.         <!-- Google Tag Manager -->
  6.         <script>(function(w,d,s,l,i){w[l]=w[l]||[];w[l].push({'gtm.start':
  7.         new Date().getTime(),event:'gtm.js'});var f=d.getElementsByTagName(s)[0],
  8.         j=d.createElement(s),dl=l!='dataLayer'?'&l='+l:'';j.async=true;j.src=
  9.         'https://www.googletagmanager.com/gtm.js?id='+i+dl;f.parentNode.insertBefore(j,f);
  10.         })(window,document,'script','dataLayer','GTM-NNW5PMM6');</script>
  11.         <!-- End Google Tag Manager -->
  12.         {% if app.request.locale == 'fr' %}
  13.         <script>
  14.         window.axeptioSettings = {
  15.         clientId: "6596c14a7d63fea42f929415",
  16.         cookiesVersion: "racket-trip/fr-fr-EU",
  17.         };
  18.         (function(d, s) {
  19.         var t = d.getElementsByTagName(s)[0], e = d.createElement(s);
  20.         e.async = true; e.src = "//static.axept.io/sdk.js";
  21.         t.parentNode.insertBefore(e, t);
  22.         })(document, "script");
  23.         </script>
  24.         {% else %}
  25.         <script>
  26.         window.axeptioSettings = {
  27.         clientId: "6596c14a7d63fea42f929415",
  28.         cookiesVersion: "racket-trip/fr-fr-EU_en-GB",
  29.         };
  30.         
  31.         (function(d, s) {
  32.         var t = d.getElementsByTagName(s)[0], e = d.createElement(s);
  33.         e.async = true; e.src = "//static.axept.io/sdk.js";
  34.         t.parentNode.insertBefore(e, t);
  35.         })(document, "script");
  36.         </script>
  37.         {% endif %}
  38.         
  39.         {% else %}
  40.         
  41.         <meta name="robots" content="noindex">
  42.             
  43.         {% endif %}
  44.         <meta charset="UTF-8">
  45.         <meta name="viewport" content="width=device-width, initial-scale=1, user-scalable=no, shrink-to-fit=no">
  46.         <link rel="icon" media="(prefers-color-scheme:light)" type="image/x-icon" href="/images/favicon-light.png" id="light-scheme-icon">
  47.         
  48.         <title>{% block title %}{% endblock %} | Racket Trip</title>
  49.         {% block seo %}{% endblock %}
  50.         {% block og %}{% endblock %}
  51.         {{ encore_entry_link_tags('app') }}
  52.         {{ encore_entry_link_tags('message') }}
  53.         
  54.         <link rel="stylesheet" href="/fontawesome/css/all.min.css">
  55.         {% block stylesheets %}{% endblock %}
  56.     </head>
  57.     {% set current_path = app.request.get('_route') %}
  58.     <body class="{{ current_path }}" id="body" onload="document.body.style.visibility=`visible`;">
  59.         <script>document.body.style.visibility=`hidden`;</script>
  60.         {% if app.request.server.get('SERVER_ENV') and app.request.server.get('SERVER_ENV') == 'production' %}
  61.         <!-- Google Tag Manager (noscript) -->
  62.         <noscript><iframe src="https://www.googletagmanager.com/ns.html?id=GTM-NNW5PMM6"
  63.         height="0" width="0" style="display:none;visibility:hidden"></iframe></noscript>
  64.         <!-- End Google Tag Manager (noscript) -->
  65.         {% endif %}
  66.         <div id="preloader">
  67.             <div class="loader" id="loader"></div>
  68.         </div>
  69.         
  70.         {% include "front/_partials/_header.html.twig" %}
  71.         {% block body %}{% endblock %}
  72.         {% include "front/_partials/_add-favorite-modal.html.twig" %}
  73.         {% if app.user and app.user.isPro %}
  74.             {#
  75.             <!-- Modal Partners Empty -->
  76.             <div class="modal fade" id="empty-partners" tabindex="-1" role="dialog" aria-labelledby="addAlert" aria-hidden="true">
  77.                 <div class="modal-dialog modal-dialog-centered" role="document">
  78.                     <div class="modal-content">
  79.                         <div class="modal-body">
  80.                             <div class="modal-title-wrap">
  81.                                 <h5 class="modal-title">{{ "courses.create_internship" | trans }}</h5>
  82.                                 <button type="button" class="close" data-dismiss="modal" aria-label="Close">
  83.                                     <i class="fal fa-times"></i>
  84.                                 </button>
  85.                             </div>
  86.                             <div class="row">
  87.                                 <div class="col-lg-12">
  88.                                     {% if app.user is instanceof('App\\Entity\\Coach') and app.user.partners | length == 0 %}
  89.                                         <p class="text-center">{{ "courses.add_club" | trans }}</p>
  90.                                     {% elseif app.user is instanceof('App\\Entity\\Club') and app.user.partners | length == 0 %}
  91.                                         <p class="text-center">{{ "courses.add_coach" | trans }}</p>
  92.                                     {% elseif app.user is instanceof('App\\Entity\\Operator') and (app.user.clubPartners | length == 0 or app.user.coachPartners | length == 0) %}
  93.                                         <p class="text-center">{{ "courses.add_club_coach" | trans }}</p>
  94.                                     {% endif %}
  95.                                     {% if app.user.proInfo.pageVisible == false %}
  96.                                         <p class="text-center">{{ "courses.publish_page" | trans }}</p>
  97.                                     {% endif %}
  98.                                 </div>
  99.                             </div>
  100.                         </div>
  101.                         <div class="modal-footer justify-content-center">
  102.                             {% if (app.user is instanceof('App\\Entity\\Coach') or app.user is instanceof('App\\Entity\\Club')) and app.user.partners | length == 0 %}
  103.                                 <a href="{{ path('pro_partners') }}" class="btn main-btn m-2">{{ "courses.add_partner" | trans }}</a>
  104.                             {% elseif app.user is instanceof('App\\Entity\\Operator') and (app.user.clubPartners | length == 0 or app.user.coachPartners | length == 0) %}
  105.                                 <a href="{{ path('pro_partners') }}" class="btn main-btn m-2">{{ "courses.add_partners" | trans }}</a>
  106.                             {% endif %}
  107.                             {% if app.user.proInfo.pageVisible == false %}
  108.                                 <a href="{{ path('pro_page') }}" class="btn main-btn m-2">{{ "header.page_pro" | trans }}</a>
  109.                             {% endif %}
  110.                         </div>
  111.                     </div>
  112.                 </div>
  113.             </div>
  114.             #}
  115.         {% endif %}
  116.         
  117.         <!-- Welcome modal -->
  118.         <div class="modal fade" id="welcome-registration" tabindex="-1" role="dialog" aria-labelledby="RegistrationTitle" aria-hidden="true">
  119.             <div class="modal-dialog modal-dialog-centered" role="document">
  120.                 <div class="modal-content">
  121.                     <div class="modal-body">
  122.                         <div class="modal-title">
  123.                             <h5 class="modal-title">{{ "modal_confirmation_registration.thanks" | trans }}</h5>
  124.                             <button type="button" class="close" data-dismiss="modal" aria-label="Close">
  125.                                 <i class="fal fa-times"></i>
  126.                             </button>
  127.                         </div>
  128.                         <div class="row">
  129.                             <div class="col-lg-12">
  130.                                 <p class="text-18 text-center">{{ "modal_confirmation_registration.message" | trans }}</p>
  131.                             </div>
  132.                         </div>
  133.                         <div class="row mt-3">
  134.                             <div class="col-md-12">
  135.                                 <button type="button" class="btn main-btn m-auto" data-dismiss="modal" aria-label="Close">{{ "membership.ok" | trans }}</button>
  136.                             </div>
  137.                         </div>
  138.                     </div>
  139.                 </div>
  140.             </div>
  141.         </div>
  142.         {% include "front/_partials/_footer.html.twig" %}
  143.         {% include "front/_partials/_responsive-navbar.html.twig" %}
  144.         {% if not chat is defined and app.user and app.request.get('_route') != 'courses' %}
  145.         {% include "front/message/floating-message.html.twig" %}
  146.         {% endif %}    
  147.         
  148.         {{ encore_entry_script_tags('app') }}
  149.         {% for label, messages in app.flashes %}
  150.             {% if label == 'welcome-registration' %}
  151.             {% for message in messages %}
  152.             <script>
  153.                 $(document).ready(function () {
  154.                     setTimeout(function () {
  155.                         $("#welcome-registration").modal({
  156.                             backdrop: 'static',
  157.                             keyboard: false
  158.                         });
  159.                     }, 200);
  160.                 });
  161.             </script>
  162.             {% endfor %}
  163.             {% elseif label != 'payment-method' and label != 'welcome' %}
  164.             {% for message in messages %}
  165.             <!-- Alert modal -->
  166.             <div class="modal fade" id="alert-modal" tabindex="-1" role="dialog" aria-labelledby="alertTitle" aria-hidden="true">
  167.                 <div class="modal-dialog modal-dialog-centered" role="document">
  168.                     <div class="modal-content">
  169.                         <div class="modal-body">
  170.                             <p class="modal-text-xl text-center font-500 mt-2 mb-0">
  171.                                 {{ message }}
  172.                             </p>
  173.                             <div class="modal-actions">
  174.                                 <button type="button" class="btn main-btn btn-sm" data-dismiss="modal" aria-label="Close">OK</button>
  175.                             </div>
  176.                         </div>
  177.                     </div>
  178.                 </div>
  179.             </div>
  180.             <script>
  181.                 $("#alert-modal").modal({
  182.                     backdrop: 'static',
  183.                     keyboard: false
  184.                 });
  185.             </script>
  186.             {% endfor %}
  187.             {% endif %}
  188.         {% endfor %}
  189.         {% block javascript %}{% endblock %}
  190.         
  191.     </body>
  192. </html>