Guest User

Untitled

a guest
Jul 24th, 2018
88
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.75 KB | None | 0 0
  1. if($_SERVER['SERVER_NAME']=="localhost") //change if local server name is different
  2. {
  3. $db_name='local_db_name';
  4. $db_username='local_db_username';
  5. $db_password='local_db_password';
  6. $db_host='local_db_host';
  7. }
  8. else // production server database credentials
  9. {
  10. $db_name='production_db_name';
  11. $db_username='production_db_username';
  12. $db_password='production_db_password';
  13. $db_host='production_db_host';
  14. }
  15.  
  16. // ** MySQL settings - You can get this info from your web host ** //
  17. /** The name of the database for WordPress */
  18. define('DB_NAME', $db_name);
  19.  
  20. /** MySQL database username */
  21. define('DB_USER', $db_username);
  22.  
  23. /** MySQL database password */
  24. define('DB_PASSWORD', $db_password);
  25.  
  26. /** MySQL hostname */
  27. define('DB_HOST', $db_host);
Add Comment
Please, Sign In to add comment