Hello, my problem is: my index.php file is in public folder ,my view about.php is in Views folder. I made a Controller About.php
PHP Code:
<?php
namespace App\Controllers;
class About extends BaseController{
public function index() {
return view('about');
}
}
?>
with route
$routes->get('/about','About::index');
but when i click on about page in URL is virtualhostrname/about.php but the index is always displayed.
.htacces file is ok rewrite engine is on
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule^([\s\S]*)$ index.php/$1 [L,NC,QSA]
.env
app.$baseURL='htttp://virtualhostname/'
in app config
public string $baseURl='http://virtualhostname/'
and always is index page and in url is virtualhostname/about.php
}