Php 代码点火器中的bitstamp实时交易

Php 代码点火器中的bitstamp实时交易,php,jquery,json,api,codeigniter,Php,Jquery,Json,Api,Codeigniter,我是位戳API的新手,我想像这样做 我正在使用php pusher库,但我不知道为什么我会得到一个 致命错误:无法重新声明类PusherException 我的HTML代码是 <table class="table table-striped table-bordered" id="" style="width: 40%;"> <thead> <tr> <th >Time Since<

我是位戳API的新手,我想像这样做

我正在使用php pusher库,但我不知道为什么我会得到一个

致命错误:无法重新声明类PusherException

我的HTML代码是

<table class="table table-striped table-bordered" id="" style="width: 40%;">
        <thead>
        <tr>
            <th >Time Since</th>
            <th >Amount</th>
            <th >Price</th>
        </tr>
        </thead>
        <tbody>
            <tr id="showDataHere">

            </tr>
        </tbody></table>

我哪里错了?

错误声明一个类声明了两次。您可以在项目级别找到
pushereException
关键字,并可以找到第二个声明的位置。这可能是由于未完成的安装

<script>
   function callMe()
    {
        $.ajax({
               type: "POST",
               url: "<?php echo base_url();?>home/live_tradess",
               success: function(response){
                          $("#showDataHere").html(response);
                        }
       });
    }

// Call it 
// "setInterval" means every 5 secs 
// "setTimeout" just once...

setInterval(callMe, 5000); </script>  
public function live_tradess()
{
    if(!class_exists('Pusher'))
        $this->load->library('Pusher');
    $this->Pusher->trigger('live_trades', 'event', array('message' => 'Hello World'));
}