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: 
If your customer account has records that are still associated to it you probably don't want to delete the user so as to maintain data integrity. Removing the actual aspnet membership record should really be a administrative exercise. 

In my opinion you should just set the `.IsApproved` flag on the user object to false and have a report that allows 

1. a manual method of making sure that an account can be deleted without affecting records (orphaned data) or
2. create a job that can safely delete the user account when `IsApproved == false`.

My vote is against deletion entirely so as to not leave your database in an inconsistent state
Call the API and delete the account? Sounds trivial. Put it into your workflow.