Yii Framework Forum: Unable to resolve the request "site". - Yii Framework Forum

Jump to content

Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

Unable to resolve the request "site". Rate Topic: -----

#1 User is offline   teppy 

  • Newbie
  • Yii
  • Group: Members
  • Posts: 2
  • Joined: 04-November 11

Posted 04 November 2011 - 08:57 PM

hi,
I.m deployed Yii an hello world demo on my hosting server with folder struct:
/httpdocs/framework
/httpdocs/protected
/httpdocs/protected/controller/sitecontroller.php
/httpdocs/index.php


Red color: i'm copy from demo 'hello world' in Yii packed download
I'm checked hosting server is ok : hxxp://toam.pro/requirements/
but when going to: my page : hxxp://toam.pro => show error :

Page Not Found

Unable to resolve the request "site".

The requested URL was not found on this server. If you entered the URL manually please check your spelling and try again.

If you think this is a server error, please contact the webmaster.

2011-11-05 08:52:19

=> check my log file have nothing error info
so how can i debug it error?

thanks for read my topic.
Teppy
0

#2 User is offline   codesutra 

  • Advanced Member
  • PipPipPip
  • Yii
  • Group: Members
  • Posts: 596
  • Joined: 15-March 11
  • Location:India

Posted 04 November 2011 - 11:29 PM

1)Kindly check the URL manager configuration in main.php file.
2)Please check a file permissions also.sometime it also create a problem.

please try this and share you feedback here.and if you get rid of from this problem by any other solution then share it here also.
CodeSutra
0

#3 User is offline   teppy 

  • Newbie
  • Yii
  • Group: Members
  • Posts: 2
  • Joined: 04-November 11

Posted 05 November 2011 - 09:31 PM

thanks for your reply
1. Default URL manager is disabled in main.php file
2. i'm try grant 777 to directory but error exits.

i'm try create new webapp, but it not run.
hxxp://toam.pro/
it show error:
CHttpException

Unable to resolve the request "site/error". (/var/www/vhosts/toam.pro/httpdocs/framework/web/CWebApplication.php:281)

#0 /var/www/vhosts/toam.pro/httpdocs/framework/base/CErrorHandler.php(280): CWebApplication->runController('site/error')
#1 /var/www/vhosts/toam.pro/httpdocs/framework/base/CErrorHandler.php(181): CErrorHandler->render('error', Array)
#2 /var/www/vhosts/toam.pro/httpdocs/framework/base/CErrorHandler.php(104): CErrorHandler->handleException(Object(CHttpException))
#3 /var/www/vhosts/toam.pro/httpdocs/framework/base/CApplication.php(709): CErrorHandler->handle(Object(CExceptionEvent))
#4 [internal function]: CApplication::handleException(Object(CHttpException))
#5 {main}

Application Log
Timestamp Level Category Message
09:23:27.092154 trace system.CModule

Loading "log" application component
in /var/www/vhosts/toam.pro/httpdocs/index.php (13)

09:23:27.095443 trace system.CModule

Loading "request" application component
in /var/www/vhosts/toam.pro/httpdocs/index.php (13)

09:23:27.098402 trace system.CModule

Loading "urlManager" application component
in /var/www/vhosts/toam.pro/httpdocs/index.php (13)

09:23:27.101763 trace system.CModule

Loading "coreMessages" application component
in /var/www/vhosts/toam.pro/httpdocs/index.php (13)

09:23:27.103816 error exception.CHttpException.404

exception 'CHttpException' with message 'Unable to resolve the request
"site".' in
/var/www/vhosts/toam.pro/httpdocs/framework/web/CWebApplication.php:281
Stack trace:
#0
/var/www/vhosts/toam.pro/httpdocs/framework/web/CWebApplication.php(136):
CWebApplication->runController('')
#1 /var/www/vhosts/toam.pro/httpdocs/framework/base/CApplication.php(158):
CWebApplication->processRequest()
#2 /var/www/vhosts/toam.pro/httpdocs/index.php(13): CApplication->run()
#3 {main} REQUEST_URI=/

09:23:27.104068 trace system.CModule

Loading "errorHandler" application component
0

#4 User is offline   shahdoost 

  • Newbie
  • Yii
  • Group: Members
  • Posts: 14
  • Joined: 30-March 12

Posted 07 May 2012 - 11:13 AM

I had the same problem, my controller name was UserManagementController, it worked just fine on windows, but when i moved it to linux, "Unable to resolve the request "usermanagement". " was shown,
The problem was that linux is casesensitive, I changed the controller name from UserManagementController to UsermanagementController and it worked!
1

#5 User is offline   Rohit.28f 

  • Junior Member
  • Pip
  • Yii
  • Group: Members
  • Posts: 23
  • Joined: 11-August 11
  • Location:Bangalore,INDIA

Posted 08 July 2012 - 10:22 PM

Hi,
may these steps work out for u..
In my case also i took files from SVN repository in to my windows , localhost dev environment and it gave me error URL not found Error404 , something like that.
Step1- Change config/main.php as follows
'urlManager' => array( 
    'urlFormat' => 'path',
    'showScriptName' => false,
    'rules' => array(              
                 	'/' => '/view',
                 	'//' => '/',
                 	'/' => '/',

            ),

        )




Step-2 Now modify ur application .htaccess file , which shoul be outside just protected folder some rewite-rules as follows....
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




Step 3- Restart your apache.and check in browser


Step4- Change http.config with Allow Override All , inplace of None.(For security point of view recheck this step).
0

#6 User is offline   Haensel 

  • Advanced Member
  • PipPipPip
  • Yii
  • Group: Members
  • Posts: 444
  • Joined: 14-January 11
  • Location:Vienna (Austria)

Posted 24 August 2012 - 01:22 PM

Thanks shahdoost! This drove me nuts until I found your hint (used Mac OS and uploaded to Linux) and this actually solved the problem!
0

#7 User is offline   Alfonso Semseo 

  • Newbie
  • Yii
  • Group: Members
  • Posts: 1
  • Joined: 13-August 13

Posted 13 August 2013 - 04:13 PM

View Postshahdoost, on 07 May 2012 - 11:13 AM, said:

I had the same problem, my controller name was UserManagementController, it worked just fine on windows, but when i moved it to linux, "Unable to resolve the request "usermanagement". " was shown,
The problem was that linux is casesensitive, I changed the controller name from UserManagementController to UsermanagementController and it worked!



Worked for me too, thanks ::)
0

#8 User is offline   Rajith R 

  • Master Member
  • PipPipPipPip
  • Yii
  • Group: Members
  • Posts: 879
  • Joined: 20-April 11
  • Location:India

Posted 14 November 2013 - 02:52 AM

its small letter problem in linux/ubuntu servers. check for either controller classname letters or model classname letters.
Rajith Ramachandran,
Wiwo inc.
| Mobile: 919995504508
0

Share this topic:


Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

3 User(s) are reading this topic
0 members, 3 guests, 0 anonymous users