| Server IP : 104.21.37.246 / Your IP : 104.23.243.32 [ Web Server : Apache System : Linux cpanel01wh.bkk1.cloud.z.com 2.6.32-954.3.5.lve1.4.59.el6.x86_64 #1 SMP Thu Dec 6 05:11:00 EST 2018 x86_64 User : cp648411 ( 1354) PHP Version : 7.2.34 Disable Function : NONE Domains : 0 Domains MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : ON | Sudo : OFF | Pkexec : OFF Directory : /home/cp648411/www/simded.com/wallpaper/banner/ |
Upload File : |
<!-- /.baner -->
<?php
$list_bn = array('table'=>'wal_banner','where'=>'status = 1 ','order'=> "ORDER BY id DESC LIMIT 0 , 5");
$view_bn = $view_db->view($list_bn);
$result_bn = $view_db->q_re($view_bn);
$num_rows_bn = mysqli_num_rows($result_bn);
$num_rows_bn;
if($num_rows_bn && $num_rows_bn>0){
?>
<div class="container-fluid no_moblie" style="padding-right: 0px;padding-left: 0px;">
<div id="carousel-example-generic" class="carousel slide" data-ride="carousel">
<!-- Indicators -->
<ol class="carousel-indicators">
<?php
for($i=1;$i<=$num_rows_bn;$i++)
{
?><li data-target="#carousel-example-generic" data-slide-to="<?php echo $i-1;?>" <?php if($i==1){?>class="active"<?php }?>></li><?php
}
?>
</ol>
<!-- Wrapper for slides -->
<div class="carousel-inner" role="listbox">
<?php
$num = 1;
while($row_bn = $view_db->q_ro($result_bn))
{
?>
<div class="item<?php if($num == 1){?> active<?php }?>">
<?php
if($row_bn['url']<>''){?> <a href="<?php echo $row_bn['url']?>" target="_blank"><?php }
?>
<img src="../../redbag/wal_banner/<?php echo $row_bn['image'];?>" >
<?php
if($row_bn['detail'] <> '')
{
?>
<div class="carousel-caption font_benner">
<div class="banner_text">
<?php
echo $util_class->sub_str3($row_bn['detail'],'145');
?>
</div>
<!--<div class="banner_bt">
<a class="btn btn-defaul bt_banner" href="#" role="button">ดูข้อความทั้งหมด...</a>
</div>-->
</div>
<?php
}
?>
<?php
if($row_bn['url']<>''){?></a><?php }
?>
</div>
<?php
$num++;
}
?>
</div>
<!-- Controls -->
<a class="left carousel-control" href="#carousel-example-generic" role="button" data-slide="prev">
<span class="glyphicon glyphicon-chevron-left" aria-hidden="true"><img src="../../image/icon_arrow_left.jpg" class="img-responsive"></span>
<span class="sr-only">Previous</span>
</a>
<a class="right carousel-control" href="#carousel-example-generic" role="button" data-slide="next">
<span class="glyphicon glyphicon-chevron-right" aria-hidden="true"><img src="../../image/icon_arrow_right.jpg" width="30" height="50" class="img-responsive"></span>
<span class="sr-only">Next</span>
</a>
</div>
</div>
<?php } ?>
<!-- /.baner -->
<style>
@media (max-width:1024px)
{
.no_moblie_next{ display:none}
}
</style>
<div class="no_moblie_next" style="position:fixed;margin-bottom: 99px;left:89%;bottom: 0;">
<a href="#top"><img src="../../image/icon_top.jpg" width="79" height="79" /></a><br><br>
<a href="https://th-th.facebook.com/simdeddotcom/" target="_blank"><img src="../../image/icon_facebook.jpg" width="79" height="79" /></a>
</div>
<script>
/*
$(document).ready(function(){
// hide #back-top first
$("#back-top").hide();
// fade in #back-top
$(function () {
$(window).scroll(function () {
if ($(this).scrollTop() > 100) {
$('#back-top').fadeIn();
} else {
$('#back-top').fadeOut();
}
});
// scroll body to 0px on click
$('#back-top a').click(function () {
$('body,html').animate({
scrollTop: 0
}, 1000);
return false;
});
});
});
*/
</script>