Login | Register | FAQ

Carousel isnt working properly

+ Post a reply

1 post Page 1 of 1

Carousel isnt working properly

by KamiCollo » Sat Apr 28, 2018 6:30 pm

So,i'm new to of this ,the bootstrap carousel isn't working for me,I took the example straight from w3school and it's still not working it only displays the images one atop of the other,my code:

<!DOCTYPE html>
<html lang="en">
<title>Pagrindinis puslapis</title>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css">
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.3.1/jquery.min.js"></script>
<script src="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/js/bootstrap.min.js"></script>


<nav class="navbar navbar-inverse">
<div class="container-fluid">
<div class="navbar-header">
<button type="button" class="navbar-toggle" data-toggle="collapse" data-target="#myNavbar">
<span class="icon-bar"></span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
<a class="navbar-brand" href="#"></a>//logotipas
<div class="collapse navbar-collapse" id="myNavbar">
<ul class="nav navbar-nav">
<li class="active"><a href="#">Pagrindinis</a></li>
<li><a href="#">Visos prekės</a></li>
<li><a href="#">Populiariausios prekės</a></li>
<li><a href="#">Nuolaidos</a></li>
<li><a href="#">Pristatymas</a></li>
<li><a href="#">Kontaktai</a></li>
<ul class="nav navbar-nav navbar-right">
<li><a href="#"><span class="glyphicon glyphicon-log-in"></span> Prisijungimas/Užsisakymas</a></li>

<div id="demo" class="carousel slide" data-ride="carousel">

<!-- Indicators -->
<ul class="carousel-indicators">
<li data-target="#demo" data-slide-to="0" class="active"></li>
<li data-target="#demo" data-slide-to="1"></li>
<li data-target="#demo" data-slide-to="2"></li>

<!-- The slideshow -->
<div class="carousel-inner">
<div class="carousel-item active">
<img src="bob.jpg" alt="Los Angeles" width="1100" height="500">
<div class="carousel-item">
<img src="young.jpg" alt="Chicago" width="1100" height="500">
<div class="carousel-item">
<img src="thing.jpg" alt="New York" width="1100" height="500">

<!-- Left and right controls -->
<a class="carousel-control-prev" href="#demo" data-slide="prev">
<span class="carousel-control-prev-icon"></span>
<a class="carousel-control-next" href="#demo" data-slide="next">
<span class="carousel-control-next-icon"></span>

<footer class="container-fluid text-center">
<p>Footer Text</p>

User avatar


  • Posts: 1
  • Joined: Sat Apr 28, 2018 6:27 pm

+ Post a reply

Page 1 of 1