Y
Y
Yura01032019-08-27 11:22:16
Slider
Yura0103, 2019-08-27 11:22:16

Including bootstrap slider file?

I'm trying to connect a slider located in a separate file to the main page file. On the main page, the slider works correctly, on the rest, only the first slide is displayed.
slider file content

<div class="container-fluid">	
  <div class="row header">
      <div id="carouselExampleIndicators" class="carousel slide col-xl-12" data-ride="carousel">
        <ol class="carousel-indicators">
          <li data-target="#carouselExampleIndicators" data-slide-to="0" class="active"></li>
          <li data-target="#carouselExampleIndicators2" data-slide-to="1"></li>
          <li data-target="#carouselExampleIndicators" data-slide-to="2"></li>
        </ol>
        <div class="carousel-inner">
          <div class="carousel-item active sl-1">						
        			</div>						
          <div class="carousel-item sl-2">
          </div>
          <div class="carousel-item sl-3">
          	</div>					
        </div>
      </div>		
    </div>

This is how I connect
<?php
  include ($_SERVER['DOCUMENT_ROOT'] ."/header.html");
?>

The connection is identical on all pages.

Answer the question

In order to leave comments, you need to log in

1 answer(s)
Y
Yura0103, 2019-08-27
@Yura0103

Tried changing the extension, didn't help. I unfortunately didn't have to use baseurl. How does he work ?

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question