Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Missing site/login
#1
After following the instructions via index.php inside my browser, I get a successful installation screen, but when I click "next" to jump to the installation, it takes me to localhost/myt/site/login, which gives a 404 Not Found message. I'm running Mac OS X Mavericks, using Safari as a browser.

I confirmed the presence of LoadModule Rewrite_module libexec/apache2/mod_rewrite.so
in my /etc/apache2/httpd.conf file.

Any suggestions for helping to complete the install?

Thanks.
Reply
#2
Hi Conrad!

Glad to see you here!

Regarding your problem can you post here ( or send via email ) your /etc/apache2/httpd.conf ? is this your first installation on mavericks of a php application that use .htaccess?

Anyway a temporary workaround while we are investigating on your problem open with a text editor the myt config file located at: /myt/protected/config/main.php


find the follwing lines:
PHP Code:
       'urlManager' => array(
 
           'urlFormat' => 'path',
 
           'showScriptName' => false,
 
           'rules' => array(
 
               '<controller:\w+>/<id:\d+>' => '<controller>/view',
 
               '<controller:\w+>/<action:\w+>/<id:\d+>' => '<controller>/<action>',
 
               '<controller:authItem>/<action:\w+>/<id:(?:[a-zA-Z0-9]+[ ]?)+[a-zA-Z0-9]+>' => '<controller>/<action>'//this is only for auth manager
 
               '<controller:\w+>/<action:\w+>' => '<controller>/<action>',
                
'<controller:charge>/<action:create>/<month:[\w-]+>/<user:\d+>/<project:\d+>' => '<controller>/<action>'//custom rule for months
 
           ),
 
       ), 

and comment out that lines:
PHP Code:
        /* -- REWRITE URL --
        'urlManager' => array(
            'urlFormat' => 'path',
            'showScriptName' => false,
            'rules' => array(
                '<controller:\w+>/<id:\d+>' => '<controller>/view',
                '<controller:\w+>/<action:\w+>/<id:\d+>' => '<controller>/<action>',
                '<controller:authItem>/<action:\w+>/<id:(?:[a-zA-Z0-9]+[ ]?)+[a-zA-Z0-9]+>' => '<controller>/<action>', //this is only for auth manager
                '<controller:\w+>/<action:\w+>' => '<controller>/<action>',
                '<controller:charge>/<action:create>/<month:[\w-]+>/<user:\d+>/<project:\d+>' => '<controller>/<action>', //custom rule for months
            ),
        ),
        -- REWRITE URL -- */ 


now your myt should be avaiable to localhost/myt/index.php

Let us know!
Reply
#3
That worked! I will email the httpd under separate cover.

Thanks!
Reply
#4
Ok we will wait your httpd.conf for trying to solve your issue.
Do not hesitate if you have more questions!
Reply
#5
Hello,

I encountered the same problem. A 404 error was displayed for mydomain/site/login after installation. Commenting out the URL rewriting in config/main.php allowed me to login and explore the features.

What was the ultimate solution to the URL rewriting issue? Was there a problem in the .htaccess file or the /etc/apache2/httpd.conf that I should check?

Thank you!
Reply
#6
Hi mzucker,
In your httpd.conf is the following line enabled ( not commented ) ?

Code:
Rewrite_module libexec/apache2/mod_rewrite.so
Reply
#7
(10-31-2014, 10:29 PM)Paolo Wrote: Hi mzucker,
In your httpd.conf is the following line enabled ( not  commented ) ?

Code:
Rewrite_module libexec/apache2/mod_rewrite.so

Thanks for your response. I'm running Ubuntu 12.04S where httpd.conf is empty. However, /etc/apache2/apache2.conf includes mods-enabled/rewrite.load which does contain this line:

Code:
LoadModule rewrite_module /usr/lib/apache2/modules/mod_rewrite.so

I also to see if the rewrite module is loaded with this result:

Code:
# apache2ctl -M
...
rewrite_module (shared)
...
Reply
#8
Hi mzucker,
Ok so this can be caused by apache directive that prevents override.
Open the default configuration file for your virtualhost, on ubuntu if I correclty rembember the path is: /etc/apache2/sites-available/default

Find ( if exists )
Code:
<Directory /var/www/ >
   AllowOverride None
</Directory>

and replace ( or add ) wtih:
Code:
<Directory /var/www/ >
   AllowOverride All
</Directory>

Let us know if this solve your issue
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)