0
votes

I am developing a Yii app using YiiBoilerPlate.

I am able to get to http://localhost/testapp/frontend/www/

when I click on login its giving me the message

The requested URL /testapp/frontend/www/site/login/ was not found on this server.

is there any config missing?

.htaccess has:

RewriteEngine on

RewriteCond %{REQUEST_FILENAME} !-f

RewriteCond %{REQUEST_FILENAME} !-d

RewriteRule . index.php

frontend/config/main.php has:

        'urlManager' => array(
            'urlFormat' => 'path',
            'showScriptName' => false,
            'urlSuffix' => '/',
            'rules' => $params['url.rules']
        ),

in the apache access logs..it has:

*127.0.0.1 - - [23/Apr/2013:18:04:24 -0500] "GET /testapp/frontend/www/site/login/ HTTP/1.1" 404 516 "http://localhost/testapp/frontend/www/" "Mozilla/5.0 (X11; Ubuntu; Linux i686; rv:20.0) Gecko/20100101 Firefox/20.0"*

Tried all relevent suggestions online and still didn't work. any ideas?

1

1 Answers

0
votes

Seems you have loginRequire on the http://localhost/testapp/frontend/www/ and it redirect you to loginUrl which does not exists.

You can easily solve it by adding to config:

// ......
'components'=>array(
   'user'=>array(
       'loginUrl'=>array('user/login'), # path to login controller/action
   ),
),

Otherwise if you don't have login controller, error will raise with message:

The requested URL /testapp/frontend/www/user/login/ was not found on this server.