skip to Main Content

Php – Create Controller Inside a folder in CodeIgniter 4

how do i create a controller inside a folder programmatically using the Spark make command ? i wrote this code: $controllerName = service('request')->getpost('controllerName'); $controllerPath = service('request')->getpost('controllerPath'); $controllerFullPath = APPPATH.'Views/'.$controllerPath; if (!is_dir($viewFullPath)) { mkdir($viewFullPath, 0777, true); } $output = shell_exec('php spark…

VIEW QUESTION

Resolving InvalidOperationException when Passing ViewBag Content List to Partial View in ASP.NET MVC

When I call the partial view inside normal view, I'm getting this error; InvalidOperationException: The model item passed into the ViewDataDictionary is of type 'System.String', but this ViewDataDictionary instance requires a model item of type 'System.Collections.Generic.List`1[EntityLayer.Concrete.Content]'. DefaultController.cs using BusinessLayer.Concrete; using…

VIEW QUESTION
Back To Top
Search