Ui folder path=> resources\views\DistributorRegitration.php
< ?php
namespace resources\views;
class DistributorRegitrationForm
{
public function distributorRegitrationFormHtml(){
return 'hello'
}
}
Controller folder path => App\Http\Controllers\DistributorRegistration.php
< ?php
namespace App\Http\Controllers;
use App\User;
use App\Http\Controllers\Controller;
use Illuminate\Http\Request;
use resources\views\DistributorRegitrationForm;
class DistributorRegistration extends Controller
{
public function VestigePOS_DistributorRegistration()
{
$distribtutor_reg_form_obj = new DistributorRegitrationForm(); //class in DistributorRegistration.php
$returned_dist_reg_html = $distribtutor_reg_form_obj->distributorRegitrationFormHtml(); // Function in DistributorRegistrationForm class.
return view($returned_dist_reg_html) ;
}
}
?>
when i called this controller Fatal error: Class 'resources\views\DistributorRegitrationForm' not found