123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120 |
- <!DOCTYPE html>
- <html lang="ru">
- <head>
- <meta charset="UTF-8">
- <title>автомобили</title>
- <link rel="stylesheet" type="text/css" href="./assets/styles/автомобили.css">
- <link rel="stylesheet" type="text/css" href="./assets/styles/авто2.css">
- <link rel="stylesheet" type="text/css" href="./assets/styles/table.css">
- <link rel="stylesheet" type="text/css" href="./assets/styles/background.css">
- <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/OwlCarousel2/2.3.4/assets/owl.carousel.min.css">
- <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/OwlCarousel2/2.3.4/assets/owl.theme.default.min.css">
- <script src="https://ajax.googleapis.com/ajax/libs/jquery/3.5.1/jquery.min.js"></script>
- <script src="https://cdnjs.cloudflare.com/ajax/libs/OwlCarousel2/2.3.4/owl.carousel.min.js"></script>
- <script src="https://cdn.jsdelivr.net/npm/papaparse@5.3.0/papaparse.min.js"></script>
- </head>
- <body>
- <div class="background">
- <img src="assets/imgs/fotka.jpg" alt="background" class="back_img">
- <img src="assets/imgs/fotka.jpg" alt="background" class="back_img">
- <div class="overlay"></div>
- </div>
- <div class="content">
- <div class="navbar">
- <a href="katalog.html">Автомобили</a>
- <a href="mainPage.html">На Главную</a>
- </div>
- <h1>Выберите свой автомобиль</h1>
- <div class="series">
- <div class="navbar">
- <a href="econom.html" id="ekonom">Эконом</a>
- <a href="komfort.html" id="comfort">Комфорт</a>
- <a href="bisnes.html" id="bizness">Бизнес</a>
- <a href="sportcar.html" id="sportcar">Спорткар</a>
- <a href="electrocar.html" id="electrocar" >Электромобили</a>
- <a href="bisnes.html" id="bizness" class="active">Поставка</a>
- </div>
- </div>
- <h1 class="in-stock">В наличии</h1>
- <div class="car-cards" id="car-cards-in-stock">
- <button id="readData">Получить данные</button>
- <div id="tableContainer"></div>
- <script>
- document.getElementById("readData").addEventListener("click", function() {
- fetch('https://raw.githubusercontent.com/nljubivaya/csv/master/postavka.csv')
- .then(response => response.text())
- .then(data => {
- Papa.parse(data, {
- encoding: 'UTF-8',
- complete: function(results) {
- const lines = results.data;
- const table = document.createElement("table");
- table.setAttribute("border", "1");
- table.setAttribute("width", "100%");
- const headerRow = table.insertRow();
- const headers = lines[0];
- headers.forEach(header => {
- const th = document.createElement("th");
- th.textContent = header;
- headerRow.appendChild(th);
- });
- for (let i = 1; i < lines.length; i++) {
- const data = lines[i];
- const row = table.insertRow();
- for (let j = 0; j < data.length; j++) {
- const td = document.createElement("td");
- td.textContent = data[j];
- row.appendChild(td);
- }
- }
- document.getElementById("tableContainer").appendChild(table);
- }
- });
- })
- .catch(error => {
- console.error('Ошибка при чтении данных:', error);
- });
- });
- </script>
- </div>
- <h1 class="in-stock">Под заказ</h1>
- <div class="carousel-container">
- <div class="owl-carousel">
- <div class="item">
- <img src="assets/katalog/biznes/b1.png" alt="1">
- </div>
- <div class="item">
- <img src="assets/katalog/biznes/b2.png" alt="2">
- </div>
-
- <div class="item">
- <img src="assets/katalog/biznes/b3.png" alt="3">
- </div>
- <div class="item">
- <img src="assets/katalog/biznes/b4.png" alt="4">
- </div>
- <div class="item">
- <img src="assets/katalog/biznes/b5.png" alt="5">
- </div>
- <div class="item">
- <img src="assets/katalog/biznes/b6.png" alt="6 ">
- </div>
- </div>
- <div class="series centered-button">
- <button id="scrollTopBtn" onclick="topFunction()" title="Вернуться в начало">Наверх</button>
- </div>
- </div>
- </div>
- <script src="assets/json/script.js"></script>
- <script src="assets/json/lentaAvto.js"></script>
- <script>
- // Функция для прокрутки наверх
- function topFunction() {
- document.body.scrollTop = 0; // Для Chrome, Safari и Opera
- document.documentElement.scrollTop = 0; // Для IE и Firefox
- }
- </script>
- </body>
- </html>
|