$(function(){
$('.header__slider').slick({
infinite: true,
fade: true,
prevArrow: '<img class="slider-arrows slider-arrows-left" src="img/arrows-left.svg" alt="">',
nextArrow: '<img class="slider-arrows slider-arrows-right" src="img/arrows-right.svg" alt="">',
asNavFor: '.slider-dots',
});
$('.slider-dots').slick({
slidesToShow: 4,
slidesToScroll: 4,
asNavFor: '.header__slider',
});
});
function print_request (json) {
var array_key = [];
$.each( json , function( key, val ){
array_key = [];
$.each( val , function( key, val ){
array_key.push(key);
});
});
var table_sql = '';
$('#table_sql').text('');
table_sql += '<table class="striped"><thead><tr>';
for(var i=0; i <array_key.length; i++) {
table_sql += '<th>'+array_key[i]+'</th>';
}
table_sql += '</tr></thead><tbody>';
$.each( json , function( key, val ){
table_sql += '<tr>';
$.each( val , function( key, val ){
table_sql += '<td>'+val+'</td>';
});
table_sql += '</tr>';
});
table_sql += '</tbody></table>';
$('#table_sql').append(table_sql);
}