<script src="<?php echo base_url('styles/js/jquery-1.12.2.min.js');?>"></script>
<script src="<?php echo base_url('styles/js/jquery-2.1.4.min.js');?>"></script>
<script src="<?php echo base_url('styles/js/bootstrap.min.js');?>"></script>
<script src="<?php echo base_url('styles/js/owl.carousel.js');?>"></script>
<script src="<?php echo base_url('styles/js/jquery.tinyscrollbar.js');?>"></script>


<script>
	$(document).ready(function() {
   var owl = $(".crypto-scroll");
      owl.owlCarousel({
        itemsCustom : [
          [0, 2],
          [360, 2],
          [600, 3],
          [767, 4],
          [1000, 5],
          [1200, 7],
          [1400, 7],
          [1600, 7]
        ],
        navigation : false,
		 pagination : false,
		loop:true,
    	autoplay:true,
    	autoplayTimeout:500,
    	autoplayHoverPause:true,
navigationText: [
     ]

      });

   
    });
	
</script>
<script src="<?php echo base_url('styles/js/highstock.js');?>"></script>
<script src="<?php echo base_url('styles/js/exporting.js');?>"></script>

<script src="<?php echo base_url('styles/js/jquery-1.12.2.min.js');?>"></script>
<script type="text/javascript" src="<?php echo base_url('styles/js/datatables.min.js');?>"></script>
<script src="<?php echo base_url('styles/js/slimscorll.js');?>"></script>

<?php
$router = service('router'); 
if($router->controllerName()=='trade')
{
?>

<script type="text/javascript">
  
  $(document).ready(function(){

    $('#slim').slimScroll({
        height: '250px'
    });

      $('#slim1').slimScroll({
        height: '650px'
    });

    $('.main-table table').dataTable({
          // "paginate": false,
          // "filter": false,
          "language": { search: "" },
          "Info": false
    });


   $('#slim1').animate({scrollTop: $('#slim1')[0].scrollHeight}, 2000);


//     var xhr1;
//     var fn1 = function(){
//         if(xhr1 && xhr1.readyState != 4){
//             xhr1.abort();
//         }
//         xhr1 = $.ajax({
//             type: 'post',
//             url: "<?php echo base_url("user/login/loadview");?>",
//             success: function(data) {

//                 $('#list').val(data);
//             }
//         });
//     };
//     var interval = setInterval(fn1, 30000);

// });




//     var xhr2;
//     var fn2=function(){

//         if(xhr2 && xhr2.readyState != 4){
//             xhr2.abort();
//         }
//         xhr2 = $.ajax({
//             type: 'post',
//             url: "<?php echo base_url("user/trade/chat_list");?>",
//             success: function(data) {
//               $("#slim1").load('user/trade/chat_list');
//               //$('#slim1').animate({scrollTop: $('#slim1')[0].scrollHeight}, 2000);
//               console.log("success");
//             }
//         });
      
//     };
//     var interval = setInterval(fn2, 5000);

// $.getJSON('user/login/chart', function (data) {

//     // create the chart
//     Highcharts.stockChart('btc', {


//         rangeSelector: {
//             selected: 1
//         },

//         title: {
//             text: ''
//         },

//         series: [{
//             type: 'candlestick',
//             name: '',
//             data: data,
//             dataGrouping: {
//                 units: [
//                     [
//                         'week', // unit name
//                         [1] // allowed multiples
//                     ], [
//                         'month',
//                         [1, 2, 3, 4, 6]
//                     ]
//                 ]
//             }
//         }]
//     });
// });


</script>

 
 <?php
}
else
{
  ?>

  <script type="text/javascript">
  
  $(document).ready(function(){
    
     
    $('.main-table table').dataTable({
          // "paginate": false,
          // "filter": false,
          "language": { search: "" },
          "Info": false
    });

   //  var xhr;

   //  var fn = function(){
   //      if(xhr && xhr.readyState != 4){
   //          xhr.abort();
   //      }
   //      xhr = $.ajax({
   //          type: 'post',
   //          url: "<?php echo base_url("user/login/loaddata"); ?>",
   //          success: function(data) {
   //              $('#custom_list').html(data);
   //          }
   //      });
   //  };
   //  var interval = setInterval(fn, 90000);



   //  var fn1=function(){

   //      if(xhr && xhr.readyState != 4){
   //          xhr.abort();
   //      }
   //      xhr = $.ajax({
   //          type: 'post',
   //          url: "<?php site_url('user/login/request');?>",
   //          success: function(data) {
   //             console.log("success");
   //          }
   //      });
      
   //  };
   //  var interval = setInterval(fn1, 1000);


   // $.ajax({
   //          type: 'post',
   //          url: "<?php site_url("user/login/result_chk");?>",
   //          success: function(data) {
   //             console.log("success");
   //          }
   //      });  



});
 </script>

  <?php
}
?>

 
<script type="text/javascript">
<?php
  //$this->load->view('user/interest');
  echo site_info('site_analytical_code');

  ?>
</script>
<script type="text/javascript">
<?php 
	echo site_info('site_live_chat_code');
?>

</script> 

<script src="<?php echo base_url();?>/styles/new_style/js/jquery-2.1.4.min.js"></script>
<script src="<?php echo base_url();?>/styles/new_style/js/bootstrap.min.js"></script>
<script src="<?php echo base_url();?>/styles/new_style/js/owl.carousel.min.js"></script>
<script src="<?php echo base_url();?>/styles/new_style/js/script.js"></script>
<script src="<?php echo base_url();?>/styles/new_style/js/wow.min.js"></script> 

  <script>
    wow = new WOW(
      {
        animateClass: 'animated',
        offset:       100,
        callback:     function(box) {
          console.log("WOW: animating <" + box.tagName.toLowerCase() + ">")
        }
      }
    );
    wow.init();
    document.getElementById('moar').onclick = function() {
      var section = document.createElement('section');
      section.className = 'section--purple wow fadeInDown';
      this.parentNode.insertBefore(section, this);
    };
  </script>

