Brad
Brad

Reputation: 1691

Codeigniter Trackback Question

I am trying to use the trackback library in codeigniter, but I am always get this

An unknown error was encountered

The following is my code(controller). There is other code validating the form etc but not effecting the trackback

    $id = $this->input->post('id');
    $ping_url = $this->input->post('ping_url');
    $title = $this->input->post('title');
    $entry = $this->input->post('entry');
    $url = "http://shivabeach.com/journal/journal_view/$id";
    if (isset($ping_url)) {
        $tb_data = array('ping_url' => $ping_url, 'url' => $url, 'title' => $title,
            'excerpt' => $entry, 'blog_name' => 'Shivabeach', 'charset' => 'utf-8');

        if (!$this->trackback->send($tb_data)) {
            echo $this->trackback->display_errors();
        } else {
            echo 'Trackback was sent!';
        }

    }

I get my trackbacks from the site I am pinging, all data come from a form that works perfectly without the trackback. I use Isset($ping_url because the backtrack field may be empty at times. I also have the trackback library autoloading

Any thoughts?

edit. I have managed to get rid of the "A PHP Error was encountered" part, now i just get the unknown error. I had a field named "class"

Upvotes: 1

Views: 1092

Answers (1)

drewjoh
drewjoh

Reputation: 1826

Do you have error reporting on (for CodeIgniter) and have it set to report all events? It looks like a CI error and the log may provide some clue as to what's going on.

Upvotes: 1

Related Questions