<pre id="cont">0</pre>
<button id="btnStart">start</button>
<pre id="cont2">0</pre>
<button id="btnStart2">start</button>
<script>
btnStart.onclick = function(){
autoCounter('#cont', 0, 10050, 12.7);
};
btnStart2.onclick = function(){
autoCounter('#cont2', 100500, 200000, 300);
};
function autoCounter(selector, from, to, step) {
const container = document.querySelector(selector);
let currValue = from;
tick();
function tick() {
if (currValue < to) {
currValue += step;
if (currValue > to) {
currValue = to;
}
container.textContent = Math.round(currValue);
window.requestAnimationFrame(tick);
}
}
}
</script>
<select id="select"></select>
const select = document.querySelector('#select');
for (let i = 1; i <= 100; i++) {
const option = document.createElement('option');
option.textContent = option.value = i;
select.append(option);
}
<header class="bggl">
<div class="bg-animation"></div>
<div class="ttop">
<div class="cnt">
<div class="nav">
<ul>
<li><a href="/" title="Каталог">Каталог</a></li>
<li><a href="/" title="О компании">О компании</a></li>
<li><a href="/" title="Медиа, новости, статьи">Медиа</a></li>
<li><a href="/" title="Контакты">Контакты</a></li>
</ul>
</div>
<div class="glcon">
контакты
</div>
</div>
<div class="cnt">
<div class="gth">
<h1>Заголовок</h1>
<p>Текст текст текст текст текст текст текст текст.</p>
</div>
</div>
</div>
</header>
.bg-animation{
background: #101402 url(https://naked-science.ru/wp-content/uploads/2016/04/article_-1_9.jpg) no-repeat center center;
background-size: auto;
background-size: cover;
transform: scale(1);
animation: pulse 20s ease-in-out infinite;
position: absolute;
top: 0;
left:0;
height: 100%;
width: 100%;
z-index: -1;
}
.bggl {
overflow: hidden;
height: auto;
min-height: 400px;
position: relative;
}
@keyframes pulse {
from {
transform: scale(1);
}
50% {
transform: scale(1.15);
}
to {
transform: scale(1);
}
}
.ttop{
padding: 25px 0 25px 0;
background: rgba(15, 23, 1, 0.5);
height: 40px;
}
.ttop>div>div:first-child,
.ttop>div>div:last-child{
flex: 1;
}
.gth{
padding: 60px 0 60px 0;
text-align:center;
}
.gth h1{
font-size:36px;
line-height: 42px;
color: #fff;
font-weight: 700;
text-transform: uppercase;
text-shadow: 1px 2px 4px rgba(0, 0, 0, 0.3);
hyphens: manual !important;
}
.gth p {
font-size: 18px;
line-height: 24px;
color: #fff;
margin-top: 5px;
text-shadow: 1px 2px 4px rgba(0, 0, 0, 0.3);
}
.cnt {
margin: 0 auto;
max-width: 1000px;
min-width: 280px;
width: 90%;
}
.nav ul li a{
color: #fff;
margin-right: 20px;
}
ul,li{
list-style-type: none;
}
.glcon {
justify-content: flex-end;
}
.ttop>div,
.nav ul,
.glcon{
display: -webkit-box;
display: -ms-flexbox;
display: flex;
}
.ttop>div{
-webkit-box-align: center;
-ms-flex-align: center;
align-items: center;
}
.bggl {
background: #101402 url(https://naked-science.ru/wp-content/uploads/2016/04/article_-1_9.jpg) no-repeat center center;
background-size: 100%;
height: auto;
min-height: 400px;
position: relative;
animation: pulse 20s ease-in-out infinite;
}
@keyframes pulse {
from {
background-size: 100%;
}
50% {
background-size: 150%;
}
to {
background-size: 100%;
}
}
.bggl {
background: #101402 url(https://naked-science.ru/wp-content/uploads/2016/04/article_-1_9.jpg) no-repeat center center;
background-size: 100% auto;
height: auto;
min-height: 400px;
position: relative;
transform: scale(1);
animation: pulse 5s ease-in-out infinite;
}
@keyframes pulse {
50% {
background-size: 150% auto;
}
}
div class="select-1"
select
.select-1 select { ... }
<label for="trigger">Пробег</label>
<strong>Выбрать</strong>
<input type="checkbox" id="trigger">
#trigger:checked ~ .prcr {
/* .pro:hover .prcr { */
display: block;
opacity: 1;
visibility: visible;
-webkit-transition-delay: 0s;
transition-delay: 0s;
}
<?php
$file='btc_status.lock';
if(!flock($lock_file = fopen($file, 'w'), LOCK_EX | LOCK_NB))
die("Already runninng\n");
include 'config_db.php';
include 'safemysql.class.php';
$db = new SafeMysql();
$fl=json_decode(file_get_contents("https://btc-e.com/api/3/ticker/btc_usd-ltc_usd?ignore_invalid=1"));
$btc=$fl->btc_usd;
if($btc->last>0)
{
//$sql = "INSERT INTO kurs SET mark = 'btce', date=NOW(), ?u"; // Для чего это?
$db->query("INSERT INTO kurs (mark, sell) VALUES ('btce',{$btc->sell})");
}
mysql_close();
?>
$(function() {
$('.owl-carousel').owlCarousel({
margin: 50,
responsiveClass: true,
items: 2,
nav: true,
navText: ["<img src='img/prev.png'>", "<img src='img/next.png'>"],
responsive: {
0: {
items: 1,
margin: 150,
center: true,
autoWidth: true,
nav: false,
navText: []
},
992: {
items: 2
}
}
});
<input type="checkbox" name="group-1" id="group-1" checked>