Moved to new host and homepage redirects

Permalink 1 user found helpful
Hiya,

Migrating a 5.6 site (will upgrade when customer can afford it) and it has a temp web address until we update the NameServers. Updated all the DB connections and config, but when I hit the temp web address, it redirects to :

http://www.mytempwebaddress.co.uk/BASE_URL/...

I can't seem to find anything in any of the configs, the .htaccess has nothing obvious, if anyone could help please?

Cheers

zapbrannigan1972
View Replies: View Best Answer
ConcreteOwl replied on at Permalink Reply
ConcreteOwl
Redacted.
zapbrannigan1972 replied on at Permalink Reply
zapbrannigan1972
Hiya. I did see your reply about the confg / site.php and yes I did look at this as well as the .htaccess file and other configs. I found places in other configs with BASE URL and commented them out and they didn't make any difference.
zapbrannigan1972 replied on at Permalink Reply
zapbrannigan1972
I've turned off Pretty URL's in the .htaccess file and there's nothing left in this file that as far as I can see would redirect the homepage.

In the public_html/config/site.php file it just has a list of definitions for DB connections and enable_cache and db_use_cache entries set to false and true respectively.

The site_themes_path.php in the same config folder just has
defined('C5_EXECUTE') or die(_("Access Denied."));
All other entries are commented out.

In public_html > concrete > config > theme_paths.php

defined('C5_EXECUTE') or die("Access Denied.");
$v = View::getInstance();
// TODO - make this honor * better, actually work for more than just dashboard
$v->setThemeByPath('/dashboard', 'dashboard');
$v->setThemeByPath('/dashboard/*', 'dashboard');
$v->setThemeByPath('/page_forbidden', VIEW_CORE_THEME);
$v->setThemeByPath('/page_not_found', VIEW_CORE_THEME);
$v->setThemeByPath('/install', VIEW_CORE_THEME);
$v->setThemeByPath('/login', VIEW_CORE_THEME);
$v->setThemeByPath('/register', VIEW_CORE_THEME);
$v->setThemeByPath('/maintenance_mode', VIEW_CORE_THEME);


Then found this in the base.php in the same location:

if (!defined('REDIRECT_TO_BASE_URL')) {
   define('REDIRECT_TO_BASE_URL', true);
}


Changed to false and voila! works! :-)
zapbrannigan1972 replied on at Permalink Reply 1 Attachment
zapbrannigan1972
Ok, this is not fully working. When I go to edit and page and SAVE, it loads the url:

https://domainname.com/BASE_URL/index.php?cID=xxx... (where xxx is the pagename) and then I found this in the bulk SEO tool (see attached).
zapbrannigan1972 replied on at Permalink Reply
zapbrannigan1972
Hi!! Anyone out there that can help me please?!

Cheers,
Andy
zapbrannigan1972 replied on at Permalink Best Answer Reply
zapbrannigan1972
Fixed it :-)

Just added

define('BASE_URL', 'http://newurlhere');

to root / config / site.php

:-)