Welcome Guest, Not a member yet? Register   Sign In
[SOLVED] Model killing the script...
#1

[eluser]überfuzz[/eluser]
A couple of weeks ago I posted the same issue, but on an other site. Seems like loading models still puzzles me... :-(

Code:
<?php if (!defined('BASEPATH')) exit('No direct script access allowed');

Model: veckobrev.php
class Veckobrev extends Model
{
    function Veckobrev()
    {
        parent::Model();
    }

    function insert_brev()
    {
        $row = array( 'rubrik' => $this->input->post('rubrik'), 'text_unparsed' => $this->input->post('text'));
        $insert = $this->db->insert('veckobrev', $row);

        if($insert)
        {
            return TRUE;
        }
    }

}

part of controller:
Code:
$this->load->model('Veckobrev');
$this->Veckobrev->insert_brev();

When I load the model I get white screen of death. Can anyone spot the error? :-(
#2

[eluser]industrial[/eluser]
[quote author="überfuzz" date="1258221941"]
Code:
Model: veckobrev.php
[/quote]

This isnt in your file, right?
#3

[eluser]überfuzz[/eluser]
[quote author="industrial" date="1258223507"][quote author="überfuzz" date="1258221941"]
Code:
Model: veckobrev.php
[/quote]

This isnt in your file, right?[/quote]
It is, why?
#4

[eluser]kierownik[/eluser]
It should be commented, with two // infront of it. That is why you get the white screen.
#5

[eluser]überfuzz[/eluser]
Right on! My bad... :red:




Theme © iAndrew 2016 - Forum software by © MyBB