templates/front/centres.html.twig line 1

Open in your IDE?
  1. {% extends 'front.html.twig' %}
  2. {% block title %}Nos centres | CIMEF-INTERNATIONAL{% endblock %}
  3. {% block styleSheets %}
  4. <style id='wp-emoji-styles-inline-css' type='text/css'>
  5. #map {
  6.     height: 500px;
  7.     width: 100%;
  8. }
  9. .title{
  10.     font-family: arial;
  11.     font-weight: bolder;
  12. }
  13. .wrap_header_banner .overlay-slider {
  14.     position: absolute;
  15.     top: 0;
  16.     left: 0;
  17.     padding-top: 30px; 
  18.     width: 100%;
  19.     height: 100%;
  20.     background-color: rgba(0, 0, 0, 0.6392156863);
  21. }
  22. .card_centre{
  23.     /*border: 1px solid #ededed;*/
  24.     border-radius: 5px; 
  25.     margin: 10px;
  26. }
  27. .card_centre:hover{
  28.     box-shadow: 0 4px 4px 0 rgba(0, 0, 0, 0.2), 0 6px 20px 0 rgba(0, 0, 0, 0.19);
  29. }
  30. .text-center{
  31.     text-align: center;
  32.     padding: 10px;
  33.     margin-top: -90px;
  34. }
  35. .titre-formation{
  36.     color: #fff;
  37.     font-weight: bold; 
  38.     font-family: arial; 
  39.     text-transform: uppercase;
  40.     font-size: 25px !important; 
  41.     text-shadow: 2px 2px 4px #000000;
  42. }
  43. .desc{
  44.     margin-top: -10px !important;
  45. }
  46. /*# sourceURL=wp-emoji-styles-inline-css */
  47. /* Small devices ≥576px */
  48. @media (min-width: 576px) {
  49.   .desc{
  50.       margin-top: 10px !important;
  51.   }
  52. }
  53. </style>
  54. {% endblock %}
  55. {% block mapjs %}
  56.     <link rel="stylesheet" href="https://unpkg.com/leaflet@1.9.4/dist/leaflet.css"/>
  57.     <script src="https://unpkg.com/leaflet@1.9.4/dist/leaflet.js"></script>
  58. {% endblock %}
  59. {% block body %}
  60. {% include 'section/navbar.html.twig' %}
  61. <div class="wrap_header_banner" style="height: 200px; background: url({{ asset('public/inter/wp-content/uploads/2023/06/header-banner.jpg')}});">
  62.     <div class="overlay-slider">
  63.         <div class="row_site">
  64.             <div class="container_site">
  65.                 <div class="cover_color"></div>
  66.                 <div class="header_banner_el">
  67.                     <div class="header_breadcrumbs">
  68.                         <div id="breadcrumbs">
  69.                         <ul class="breadcrumb">
  70.                             <li><a href="{{ path('front.inter.index') }}" style="color: #fff!important;" title="accueil">Accueil</a></li>
  71.                             <li class="li_separator"><span class="separator"><i class="ovaicon-next" style="color: #fff!important;"></i></span></li>
  72.                             <li style="color: #fff!important;">Nos centres</li>
  73.                         </ul>
  74.                         </div>
  75.                     </div>
  76.                     <h1 class="header_title" style="color: #fff!important;">Nos centres </h1>
  77.                 </div>
  78.             </div>
  79.         </div>
  80.     </div>
  81. </div>
  82. <div style="padding-top: 50px; padding-bottom: 50px;" data-elementor-type="wp-page" data-elementor-id="405" class="elementor elementor-405">
  83.    <section class="elementor-section elementor-top-section elementor-element elementor-element-574990e elementor-section-boxed elementor-section-height-default elementor-section-height-default" data-id="574990e" data-element_type="section">
  84.       <div class="elementor-container elementor-column-gap-no">
  85.          <div class="elementor-column elementor-col-120 elementor-top-column elementor-element elementor-element-eabb843" data-id="eabb843" data-element_type="column">
  86.             <div class="elementor-widget-wrap elementor-element-populated">
  87.                <div class="elementor-element elementor-element-a45a98c elementor-widget elementor-widget-gimont_elementor_heading" data-id="a45a98c" data-element_type="widget" data-widget_type="gimont_elementor_heading.default">
  88.                   <div class="elementor-widget-container">
  89.                      <div class="ova-heading template_1" style="padding-left: 50px; padding-right: 50px;">
  90.                         <span class="line" style="background-color: #ff6600 !important;"></span>
  91.                         <span class="subtitle" style="color: #ff6600 !important;">Nos centres</span>
  92.                         <h2 class="title" style="font-size: 28px; color: #051a53 !important;">Nos centres de formations</h2>
  93.         
  94.                         <p class="desc">
  95.                             Présent à Abidjan, Paris, Dakar et Casablanca, le CIMEF vous accompagne dans vos projets de formation, de reconversion professionnelle ou de 
  96.                             développement d’entreprise.Nos équipes locales sont disponibles pour vous conseiller et répondre à toutes vos questions sous 24h.</p>
  97.                      <br>
  98.                         <div class="row">
  99.                             {% if ville != null %}
  100.                                 {% for vil in ville %}
  101.                                 <div class="col-lg-4 col-md-4 col-sm-12">
  102.                                     <a href="{{ path('front.detail.centre',{'slug': vil.slug}) }}">
  103.                                     <div class="card_centre" style="padding: 10px;">
  104.                                         {% if vil.image !=null %}
  105.                                             <img loading="lazy" style="border-top-left-radius: 5px; border-top-right-radius: 5px; width: 100%; height: 250px;" src="{{ asset('public/uploads/images/actualites/' ~ vil.image) }}" 
  106.                                             class="attachment-ovaev_event_thumbnail size-ovaev_event_thumbnail wp-post-image" alt="{{ vil.nom }}" decoding="async" 
  107.                                             srcset="{{ asset('public/uploads/images/centres/' ~ vil.image) }}" sizes="(max-width: 600px) 100vw, 600px" />
  108.                                         {% else %}
  109.                                             <img loading="lazy" style="width: 100%; height: 250px;" src="{{ asset('public/inter/logo-inter.jpg') }}" 
  110.                                             class="attachment-ovaev_event_thumbnail size-ovaev_event_thumbnail wp-post-image" alt="Logo CIMEF INTERNATIONAL"
  111.                                             sizes="(max-width: 600px) 100vw, 600px"/>
  112.                                         {% endif %}
  113.                                         <div class="text-center">
  114.                                             <h2 class="titre-formation">{{ vil.nom }}</h2>
  115.                                         </div>
  116.                                     </div>
  117.                                     </a>
  118.                                 </div>
  119.                                 {% endfor %}
  120.                             {% endif %}
  121.                         </div>
  122.                      </div>
  123.                      <div style="margin-top: 80px; margin-bottom: 80px; border: 7px solid #ededed;">
  124.                          <div id="map"></div>
  125.                      </div>
  126.                          
  127.                   </div>
  128.                </div>
  129.             </div>
  130.          </div>
  131.       </div>
  132.     </section>
  133.    
  134.     <script>
  135.     
  136.         var customIcon = L.icon({
  137.             iconUrl: 'https://raw.githubusercontent.com/pointhi/leaflet-color-markers/master/img/marker-icon-red.png', // Changer ici pour une autre couleur
  138.             shadowUrl: 'https://cdnjs.cloudflare.com/ajax/libs/leaflet/1.7.1/images/marker-shadow.png',
  139.             iconSize: [25, 41],  // Taille du marqueur
  140.             iconAnchor: [12, 41], // Ancre du marqueur
  141.             popupAnchor: [1, -34] // Position du popup
  142.         });
  143.         
  144.         var map = L.map('map').setView([20, 0], 2); // Vue centrée sur la France
  145.     
  146.         L.tileLayer('https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png', {
  147.             attribution: '&copy; OpenStreetMap contributors'
  148.         }).addTo(map);
  149.     
  150.         var locations = {{ locations|json_encode|raw }};
  151.         var markers = [];
  152.     
  153.         locations.forEach(function(location) {
  154.             var marker = L.marker([location.lat, location.lng], { icon: customIcon }).addTo(map)
  155.                 .bindPopup(location.ville);
  156.             markers.push(marker);
  157.         });
  158.     
  159.         function zoomOn(lat, lng) {
  160.             map.setView([lat, lng], 12); // Zoom sur la position
  161.         }
  162.     
  163.     
  164.         function zoomOn(lat, lng) {
  165.             map.setView([lat, lng], 12);
  166.             
  167.             // Trouver et ouvrir la popup du marqueur correspondant
  168.             markers.forEach(function(marker) {
  169.             var position = marker.getLatLng();
  170.             if (position.lat === lat && position.lng === lng) {
  171.                 marker.openPopup();
  172.             }
  173.         });
  174.     }
  175.     </script>
  176.    
  177. </div>
  178. {% include 'section/footer.html.twig' %}               
  179. {% endblock %}