Re: URI problem

2009-07-16 Thread Marcelo Andrade

On Wed, Jul 15, 2009 at 5:23 PM, Yc Zhang wrote:
>
> and I add a line of RewriteBase to public_html/cake/app/weboot folder
>  RewriteBase /~username/cake/


CakePHP has three .htaccess files.  Besides the
one at public_html/cake/app/webroot, try adding
the RewriteBase to the others too, in your case,
at public_html/cake and public_html/cake/app.

Best regards.

--
MARCELO DE F. ANDRADE
Belem, PA, Amazonia, Brazil
Linux User #221105

http://mfandrade.wordpress.com

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To post to this group, send email to cake-php@googlegroups.com
To unsubscribe from this group, send email to 
cake-php+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/cake-php?hl=en
-~--~~~~--~~--~--~---



URI problem

2009-07-15 Thread Yc Zhang

I install cake like this:
/path/to/my/username/public_html/cake/app/
/path/to/my/usernamepublic_html/cake/cake/lib
/path/to/my/username/public_html/cake/index.php

I can access the cake by:
http://web.domain.edu/~username/


I add .htaccess to the public_html folder

  RewriteEngine On
  RewriteBase /~username/cake/
  RewriteRule  ^$ app/webroot/ [L]
  RewriteRule (.*) app/webroot/$1 [L]


I add .htaccess to the public_html/cake folder

  RewriteEngine On
  RewriteBase /~username/cake/
  RewriteRule  ^$ app/webroot/ [L]
  RewriteRule (.*) app/webroot/$1 [L]


and I add a line of RewriteBase to public_html/cake/app/weboot folder
  RewriteBase /~username/cake/

but the problem comes like this:

I can access my home page like http://web.domain.edu/~username/

while I click the link in my cake application, it goes to:
http://web.domain.edu/controller_name/action_name
rather than:
http://web.domain.edu/~username/controller_name/action_name

How can I add ~username in the url before the controller name?

Thanks in advance.

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To post to this group, send email to cake-php@googlegroups.com
To unsubscribe from this group, send email to 
cake-php+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/cake-php?hl=en
-~--~~~~--~~--~--~---