0

Our website randomly started showing this error whenever you access a link outside of the home page or try to access the admin panel.

Exception #0 (FishPig\WordPress\Model\Integration\IntegrationException): Your home URL (https://www.ourURL.com/documents) is invalid as it does not start with the Magento base URL (https://www.ourURL.com/home).

The weird thing is that it the base URL should be https://www.ourURL.com/ (without the /home/). When I SSH into the server and run n98-magerun2 sys:store:config:base-url:list I can see that the base and base secure URLs are set correctly.

I've tried running the following commands.

php bin/magento setup:store-config:set --base-url="http://www.ourURL.com/"
php bin/magento setup:store-config:set --base-url-secure="https://www.ourURL.com/"

(I even tried setting it to http(s)://www.ourURL.com/home/ and then setting it back)

php bin/magento c:f
php bin/magento setup:static-content:deploy -f
php bin/magento cache:clean
php bin/magento cache:flush

I'm kinda out of ideas and have a support ticket open with our web hosting provider, but in the mean time any suggestions would be greatly appreciated.

2 Answers 2

0
1. Set your WordPress setup folder name "wp".

2. M2 Admin Menu > WordPress > Path = wp

3. Database: wordpress_database > Table: wp_options

option_id = 1
option_name = siteurl
option_value = http://www.example.com/wp //Folder name of your WordPress installation.
autoupload = yes

option_id = 2
option_name = home
option_value = http://www.example.com/blog //Frontend URL
autoupload = yes

For more click here :

Magento 2 - Wordpress Integration url issue

https://fishpig.co.uk/magento/wordpress-integration/docs/

0

Issue resolved. Running php bin/magento setup:store-config:set --base-url="http://www.ourURL.com/"changed the value under web/unsecure/base_url. The issue was that I needed to change web/unsecure/base_link_url to match it.

Ran the following command for both secure and unsecure.

bin/magento config:set web/unsecure/base_link_url 'https://www.ourURL.com/' 

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.