Welcome Guest, Not a member yet? Register   Sign In
Problem with loading libraries
#1

[eluser]Unknown[/eluser]
Sorry for my writing, my english is poor, but i have a problem with load a libraries, in the version 2.0 CI

in the next example taken of the user guide

Code:
$this->load->library('table');

$data = array(
             array('Name', 'Color', 'Size'),
             array('Fred', 'Blue', 'Small'),
             array('Mary', 'Red', 'Large'),
             array('John', 'Green', 'Medium')
             );

echo $this->table->generate($data);

it gives me

Code:
A PHP Error was encountered

Severity: Notice

Message: Undefined property: CI_Loader::$table

Filename: views/lista_de_series.php

Line Number: 29

however, load library in autoload

Code:
$autoload['libraries'] = array('table');

result is correct

don't understand why

thank you for help me
#2

[eluser]Unknown[/eluser]
¿Possible bug?
#3

[eluser]markup2go[/eluser]
Did you try loading the library from a controller rather than a view?




Theme © iAndrew 2016 - Forum software by © MyBB