Question: There is /localhost/domains/localhost/myCakephpApp on web server. I can't do anything with folder structure, but I can edit .htaccess in /localhost/, which now simplified looks like this:

```
RewriteRule (.*) /domains/localhost/$1 [L]

```

My website in localhost/domains/localhost/myCakephpApp has standard cake .htaccess file:

```
RewriteRule    ^$ app/webroot/    [L]
RewriteRule    (.*) app/webroot/$1 [L]

```

It is nice that <http://localhost/whatever/> works, but all links in cakephp (done with html helper) are pointing to <http://localhost/domains/localhost/whatever/> and it is accessible.

What should I do to make the website running only on <http://localhost/> and not on <http://localhost/domains/localhost/>?

EDIT:

Okay, I have modified the .htaccess in root (http://localhost/):

```
RewriteRule ^$ /domains/localhost/app/webroot/ [L]
RewriteRule (.*) /domains/localhost/app/webroot/$1 [L]

```

and deleted one in <http://localhost/domains/localhost/> which means that the web is only accessible from <http://localhost>, but links are still pointing at <http://localhost/domains/localhost/whatever> (e404)

Is there something in cake's routing like "base url"? I have searched a lot, but nothing worked.

Answer: 
You should set the MembershipUser.IsApproved to false and call [Membership.UpdateUser()](http://msdn.microsoft.com/en-us/library/system.web.security.membership.updateuser.aspx) to save the update.

```
MembershipUser membershipUser = Membership.GetUser("MyUserName");
if (membershipUser!= null){
    membershipUser.IsApproved = false;
    Membership.UpdateUser(membershipUser);
}

```
Call the API and delete the account? Sounds trivial. Put it into your workflow.