Jump to content

  •  

- - - - -

Change Domain Properly & Safely


  • Please log in to reply
1 reply to this topic

#1 Pleco

Pleco

    Member

  • Member
  • PipPip
  • 19 posts

Posted 01 November 2018 - 12:35 PM

Hello! I just bought a new domain for my forums, I was wondering how can I safely change my domain over without breaking anything? I saw a few tutorials here and there on the forums but they're bits and pieces or not very descriptive, is there a tutorial out there that anybody would recommend?
Thank you!

Edit: When I go to conf_global and change the URL there, it works although there's a lot of broken aspects. Is there a fix for this?

Posted Image


Nevermind, I reloaded my cache on my theme and flushed cache on Cloudflare and everything works perfectly and old URLs automatically redirect to the new ones so no links to posts got broken. :)

Edited by Pleco, 01 November 2018 - 04:00 PM.


#2 OsitoPunk

OsitoPunk

    Advanced Member

  • Member
  • PipPipPip
  • 73 posts

Posted 09 November 2018 - 06:57 AM

Please be sure to take a backup of your database before running any manual queries.



Edit ibf_ to your prefix or remove if your not using one.





UPDATE ibf_posts SET post=REPLACE(post, 'OLD URL', 'NEW URL') 


Or...


The next thing you will need to do is export your website’s database. You can easily do that using a database management tool like phpMyAdmin. To find which database your website uses, open the file called conf_global.php. You can find the name of your database on the following line:
$INFO[‘sql_database’] = ‘database_name’;

The text between the second quotes will be the name of your database.

The next step is to create a new MySQL database. Login to your cPanel and find the MySQL Database Wizard icon. Simply enter the details for your database and its users. Once you have created the MySQL database, head to phpMyAdmin and import the previously exported copy of your site’s database.
As a final step, you will need to open the file conf_global.php with a text editor like notepad. The file is located in your IPB root directory. Find the following lines and edit them with the MySQL details that you have created earlier:
$INFO[‘sql_host’] = ‘localhost’;

$INFO[‘sql_database’] = ‘database_name’;

$INFO[‘sql_user’] = ‘database_user’;

$INFO[‘sql_pass’] = ‘password’;

Replace “database_name”, “database_user” “password” with the MySQL database details that you have created earlier. Save the file and upload it again in your account to make sure the file is active.

Edited by OsitoPunk, 09 November 2018 - 07:04 AM.





0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users