I have a Drupal 7 development site that is a subdomain of the production site, eg. dev.prod.com, for example.
When ever I create a content type, new content, a new user, install a new module, etc on the development site it redirects to the production URL after the form is submitted. I don't have permission on production so I get "access denied". When I go back to the development site and refresh the browser, the content have been created. But this does not work for installing a module. The module is not installed. Obviously, this makes it impossible to work on dev.
I have reviewed .htaccess and settings.php for any rewrite rules that could be causing this but I have not found anything. $base_url is set to the correct URL for the development server. I have cleared the cache many times.