I'm trying to use Laravel'4 Eloquent outside of the framework, since the Illuminate/Database package as been made availabile stand-alone via composer.
Eloquent itself is working fine, but I'm blocked trying to implement validation rules.
I've tried first with some pre-built library like Ardent and then with my own code but the result it's the same, I got this fatal-error:
Fatal error: Call to a member function make() on a non-object in vendor\illuminate\support\Illuminate\Support\Facades\Facade.php on line 177
The problem always start when I call Validator::make();
$validator = Validator::make(
$this->attributes,
array('name' => 'required')
);
Looking in debug it seems that static::resolveFacadeInstance('validator');
is called but it just return null
.
I'm not familiar about how a Facades are meant to work, can anyone point me in the right direction? Thank you!
This is my composer.json:
{
"require": {
"illuminate/database": "~4.0",
"illuminate/validation" : "~4.0",
"laravelbook/ardent": "dev-master"
},
"config": {
"preferred-install": "dist"
},
"minimum-stability": "dev"
}
"illuminate/validation": "4.0.*@dev"
and database with"illuminate/database": "4.0.*@dev"
? – Muhammad Usman