this is most likely a simple answer that i have overlooked..
I am trying to create a customer controller that accesses a custom model in FuelPHP as follows:
class Controller_Casting extends Controller
{
public function action_index()
{
Model_casting::author_get();
}
}
class Model_casting
{
public function author_get()
{
$query = DB::query('SELECT * FROM youtube_author');
$result = $query->execute();
print_r($result);
}
}
An error is generated by the controller:
ErrorException [ Error ]: Class 'Model_casting' not found
In code igniter i would have to load the model before using it.. How do you do the same thing in FuelPHP (which i presume is where the issue lies).. The docs though indicate that it should auto load?
Thanks,