Category : model-view-controller

I have starter laravel app, when I access the login page, shows to me "This page isn’t working right now", I don’t see any errors in my code my loginController: <?php namespace AppHttpControllersAuth; use AppHttpControllersController; use IlluminateHttpRequest; class LoginController extends Controller { public function __construct() { $this->middleware([‘auth’]); } public function index(){ return view(‘auth.login’); } public ..

Read more

Undefined variable: blogcat (View: /home/techpriest/joseph/resources/views/admin/view_category.blade.php) this is my error message in laravel 8 but when I look at my code all seems well. here is my code. AdminController public function addBlogCat (Request $request){ if ($request->isMethod(‘post’)) { $data = $request->all(); $blogcat = new Foliocategories; $blogcat->name = $data[‘category_name’]; $blogcat->save(); return redirect (‘/blog/categories’); } return view (‘admin.view_category’); } ..

Read more

I made the show details feature using a button, when I click the detail button the data doesn’t appear. why when I click the detail page detail button doesn’t show: This is my code: Controllers mahasiswa.php <?php defined(‘BASEPATH’) or exit(‘No direct script access allowed’); class Mahasiswa extends CI_Controller { public function index() { $data[‘mahasiswa’] = ..

Read more

i get this error from my index page that is the only view page in the Model View Controller(MVC) project i have and with the code below in my index page <?php define("ROOT", dirname(__DIR__) . DIRECTORY_SEPARATOR); define("APP",ROOT . "app" . DIRECTORY_SEPARATOR); define("VIEW", ROOT . "app". DIRECTORY_SEPARATOR . "view" . DIRECTORY_SEPARATOR); define("MODEL",ROOT . "app" . DIRECTORY_SEPARATOR ..

Read more

I’m noob in MVC, now I’m creating the Auth for the first time when I open the register route : Fatal error: Uncaught TypeError: Argument 1 passed to appcontrollersAuthController::register() must be an instance of appcontrollersRequset, instance of appcoreRequest given in C:controllersAuthController.php:19 Stack trace: #0 [internal function]: appcontrollersAuthController->register(Object(appcoreRequest)) #1 C:MVCcoreRouter.php(57): call_user_func(Array, Object(appcoreRequest)) #2 C:MVCcoreApplication.php(30): appcoreRouter->resolve() #3 ..

Read more