Codeigniter and connector

Hi,

So I tried following the tutorial here:
docs.dhtmlx.com/tutorials__conne … step5.html

Unfortunately I ran into some issues as illustrated below:

I searched in the forums and saw that the connectors were a bit outdated (2 years), so I went ahead and updated them to the version from github.

Unfortunately this changed nothing.

I have outlined the line from the error below

In the data method

$connector = new SchedulerConnector($this->db, "PHPCI");

I have also outlined the following error:

To this return (so that $this->connection is not an object):

public function escape_name($data){ return $this->connection->protect_identifiers($data); }

I know my database is configured correctly, as it works perfectly fine on other pages, and with other codeigniter libraries.

I couldn’t seem to be able to edit my post.

I have attached my server file below:

[code]<?php if ( ! defined(‘BASEPATH’)) exit(‘No direct script access allowed’);

require_once("./dhtmlx/connector/scheduler_connector.php");
require_once("./dhtmlx/connector/db_phpci.php");
DataProcessor::$action_param =“dhx_editor_status”;

class ScheduleServer extends CI_Controller {

public function __construct()
{
}

public function index()
{
    $this->admin();
}

public function data()
{
    //Auto loaded
    //$this->load->database();

    $connector = new SchedulerConnector($this->db, "PHPCI");
    $connector->configure(
        "tasks",
        "id",
        "start_date, end_date, subject"
    );
    $connector->render();
}

public function beforeRender($action){
    if ($action->get_id() == 10)
        //marks an event if its id is 10
        $action->set_userdata("color", "pink");
}

public function beforeProcessing($action){
    //validation before saving
    if ($action->get_value("event_name") == ""){
        $action->invalid();//calls $action->invalid() if data fails validation
        $action->set_response_attribute("details", "Empty data not allowed");
    }
}

}[/code]