2013-07-23 42 views

回答

2

你需要做以下步驟:對笨here

  • tumblr.php

    1. 下載的tumblr的API庫(在config文件夾中)把你的config文件夾
    2. 變更與配置文件的參數:

      $config['tumblr_consumer_key']   = ''; 
      $config['tumblr_secret_key']   = ''; 
      $config['tumblr_url']     = 'good.tumblr.com'; 
      $config['callback_url']     = 'controller/method'; 
      $config['auth_callback']    = 'controller/method'; 
      
    3. 將Tumblr.php(在庫文件夾中)放在您的庫文件夾中

    4. OAuth.php(位於third_party文件夾中)放在您的third_party(創建如果不存在)。
    5. 使用它。例如:
    $this->load->library('Tumblr'); 
    $blog_info = $this->tumblr->blog_info(); 
    // Blog info returned in object 
    echo $blog_info->title; // echo blog title 
    
  • +0

    我檢查,一出還可以,但我不知道程序如何作出適當的身份驗證請求。 – jonathanwiesel

    +1

    沒關係,我設法編輯庫代碼以使它適合我的需要,謝謝 – jonathanwiesel

    +0

    很高興聽到你做到了。不用謝! –

    相關問題