auspayday
Forum Replies Created
-
Forum: Networking WordPress
In reply to: Can’t access site after changing wp-config and htaccessIt’s possible that there was an error in the changes you made to the wp-config.php or .htaccess files that is causing the issue with accessing your site. Here are a few things you can try to troubleshoot the issue:
- Check the wp-config.php file for errors: Double-check that you made the correct changes to the wp-config.php file, such as adding the necessary code to enable multisite. Make sure there are no syntax errors or typos in the code. You can use a code editor or an online syntax checker to help you find any errors.
- Check the .htaccess file for errors: If you made changes to the .htaccess file, make sure you didn’t accidentally delete any important code or add any extra characters. Check that the code you added is correct and in the right place. You can use a code editor or an online syntax checker to help you find any errors.
- Restore the original wp-config.php and .htaccess files: If you have a backup of your wp-config.php and .htaccess files from before you made changes, you can restore those files to see if that fixes the issue. If you don’t have a backup, you can create a new wp-config.php and .htaccess file by reinstalling WordPress.
- Check your server logs: If none of the above steps work, check your server logs to see if there are any error messages that could indicate what’s causing the issue. You can usually access your server logs through your hosting control panel or by contacting your hosting provider.
If none of these steps resolve the issue, you may need to seek additional help from a WordPress developer or your hosting provider.
To copy a subdomain site within a WordPress Multisite network from one server to another using WP CLI, you can follow these steps:
- Export the site content from the production server using WP CLI’s export command. Run the following command:
wp export --dir=/path/to/export/folder
This will create an XML file in the specified folder that contains all the site’s content. - Copy the exported XML file to the development server.
- Create a new subdomain site on the development server using WP CLI’s site create command. Run the following command:
wp site create --slug=devsite --title="Development Site" --network=dev.abc.com
Replace “devsite” with the desired subdomain slug and “Development Site” with the desired site title. Replace “dev.abc.com” with the development network’s subdomain. - Import the site content into the new subdomain site using WP CLI’s import command. Run the following command:
wp import /path/to/export/folder/exported_file.xml --authors=create
This will import the site content into the new subdomain site. The –authors=create flag will create new user accounts for any authors who are not already present on the development server. - Update any URLs that may be hardcoded in the site’s content using WP CLI’s search-replace command. Run the following command:
wp search-replace 'prod.abc.com' 'dev.abc.com/devsite' --skip-columns=guid
This will update any instances of the production subdomain URL in the site’s content to the development subdomain URL. Replace “devsite” with the subdomain slug you used in step 3. - Test the new subdomain site on the development server to ensure everything is working as expected.
Note: Make sure to backup your production site before attempting to export, and your development site before running the import and search-replace commands.
Forum: Networking WordPress
In reply to: Multisite Links not WorkingBased on the information provided, it’s possible that there may be an issue with the subdomain’s DNS configuration. Here are a few things you can check:
- Check that the DNS records for the subdomain are still pointing to the correct server. You can do this by looking up the DNS records for the subdomain using a tool like MX Toolbox.
- Check that the subdomain is still configured in the WordPress multisite network. Go to the Network Admin dashboard and navigate to Sites > All Sites. Look for the subdomain site and make sure it is still listed.
- Check that the subdomain’s URL is correct in the site’s settings. Go to the subdomain site’s dashboard and navigate to Settings > General. Make sure the WordPress Address (URL) and Site Address (URL) are both set to the correct subdomain URL (e.g. https://alberta.energywerx.ca).
- Check that there are no conflicting plugins or settings that may be redirecting the subdomain to the main site. Try disabling any recent plugins or settings changes to see if that resolves the issue.
If none of these steps resolve the issue, it may be helpful to reach out to your web host or a WordPress developer for further assistance.
To access your WordPress multisite with an alternative URL, you will need to set up domain mapping. Domain mapping is the process of pointing a domain name to a specific site in your WordPress multisite network.
Here are the steps to set up domain mapping:
- Install and activate a domain mapping plugin, such as WordPress MU Domain Mapping or Domain Mapping System.
- Go to the Network Admin dashboard and navigate to Settings > Domain Mapping.
- Enter the primary domain name of your WordPress multisite network in the “Server IP Address” field.
- In the “Add New Domain” section, enter the alternative domain name (Backup.Site.com) that you want to use to access your WordPress multisite network.
- Click the “Add Domain” button and wait for the plugin to create the necessary DNS records.
- Once the DNS records have propagated, you should be able to access your WordPress multisite network using the alternative domain name (Backup.Site.com) and the subdirectory paths (Backup.Site.com/w1, Backup.Site.com/w2).
Note: You may also need to update your site URLs in the wp_options table for each site in your network to ensure that links and media work correctly. This can be done using a tool such as the Better Search Replace plugin.