I'm building www.mynewcraftsite.com.au, but I also wanna create www.mynewcraftsite.dev which is a testing server to preview to my clients. I've heard that I can set this up with Craft without going through the drudgery of downloading/uploading databases and updating urls in the db, users ... etc.
I've been reading the Craft CMS documentation for "Multi-Environment Configs". So far I've got this in my db.php file;
return array( //All environments '*' => array( 'omitScriptNameInUrls' => true, 'localhost' or '127.0.0.1'. 'server' => 'localhost', 'user' => 'dashing-print', 'password' => 'f#$njEwFRn3&2', 'database' => 'dashing-print', 'tablePrefix' => 'craft' ), //Testing environment 'www.mynewcraftsite.dev' => array( 'siteUrl' => 'www.dashingprint.dev' ), //Live environment 'www.mynewcraftsite.com.au' => array( 'siteUrl' => 'www.dashingprint.com.au' ) );
It works EXCEPT when I go to www.mynewcraftsite.dev and then click on the links, I end up back on www.mynewcraftsite.com.au (eg. Instead of going to www.mynewcraftsite.dev/services, I go to www.mynewcraftsite.com.au/services. In order to get to the correct page I gotta write up the whole url www.mynewcraftsite.dev/service into the google chrome url bar.)
The siteURL property isn't doing anything, there's gotta be something else that I gotta stick in there in order to rewrite the urls.