CodeIgniter Forums
Need help integrating zencoder libraries with codeigniter - Printable Version

+- CodeIgniter Forums (https://forum.codeigniter.com)
+-- Forum: Archived Discussions (https://forum.codeigniter.com/forumdisplay.php?fid=20)
+--- Forum: Archived Development & Programming (https://forum.codeigniter.com/forumdisplay.php?fid=23)
+--- Thread: Need help integrating zencoder libraries with codeigniter (/showthread.php?tid=58312)



Need help integrating zencoder libraries with codeigniter - El Forum - 06-01-2013

[eluser]bluepicaso[/eluser]
I am looking for some quick help. I am trying to integrateZencoder php library
i copied everything to libraries folder.
then in my controller
Code:
<?php if ( ! defined('BASEPATH')) exit('No direct script access allowed');

class Video extends CI_Controller {


function __construct()
  {
  parent::__construct();
                $this->load->library('Services_Zencoder');
  }

/*
  * function index
  * @param
  * desc desc
  */

function index() {
  $encoding_job = $this->Services_Zencoder->createData('
   {
    "api_key": "MY API KEY XXXXXXXXXXXXXXXXXXXXX",
    "input": "s3://bucket-name/file-name.avi",
    "outputs": [
     {
      "label": "web"
     }
    ]
   }
  ');
}
}
i get an error
Fatal error: Call to a member function createData() on a non-object in /var/www/mweb/application/controllers/video.php on line 19

i am working on a project where we require video uploads. Any help will be appreciated.



Need help integrating zencoder libraries with codeigniter - El Forum - 06-01-2013

[eluser]pzntec[/eluser]
Have you loaded the library via the autoload file or $this-library-load() function?


Need help integrating zencoder libraries with codeigniter - El Forum - 06-02-2013

[eluser]bluepicaso[/eluser]
oh well, instead i used the API via Curl library, that served better.


Need help integrating zencoder libraries with codeigniter - El Forum - 06-02-2013

[eluser]pzntec[/eluser]
Sorry, I am not familiar with CURL so I can't help you there.. Maybe someone else can.