I tried to remove index.php from url by many ways, but without results.
My OS is Ubuntu Linux.
Server Apache.
In web.php in config directory
Still not working
I try to created .htaccess in web direcory
Still without result
In result
404 Not Found
Please help me to resolve problemRead more
My OS is Ubuntu Linux.
Server Apache.
In web.php in config directory
<?php
$config = [
'components' => [
'urlManager' => [
'class' => 'yii\web\UrlManager',
'enablePrettyUrl' => true,
'showScriptName' => false,
'rules' => [
'/' => 'site/index',
'login' => 'site/login',
'<controller:\w+>/<id:\d+>' => '<controller>/view',
'<controller:\w+>/<action:\w+>/<id:\d+>' => '<controller>/<action>',
'<controller:\w+>/<action:\w+>' => '<controller>/<action>',
],
],
]
]
Still not working
I try to created .htaccess in web direcory
RewriteEngine on
# If a directory or a file exists, use it directly
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
# Otherwise forward it to index.php
RewriteRule . index.php
Still without result
In result
404 Not Found
Not Found
The requested URL /login was not found on this server.
Apache/2.4.18 (Ubuntu) Server at tracker.dev Port 80
Please help me to resolve problemRead more