Before you start
You need administrator access to your WordPress website.
Your web host needs PHP 7.2 or later with Libsodium.
Switching to a custom website turns off your WithWine landing and eCommerce pages. Your WordPress website takes their place.
If your website uses page caching, set up the caching exceptions before you go live. See "Which pages must not be cached when using the WithWine WordPress plugin?".
Step 1: Get your website credentials from WithWine
In WithWine, go to Settings > Website.
In How will people access your website?, choose Custom Domain Name (eg: yourdomain.com) - Additional Setup Required.
In Custom domain, type your WordPress website's domain without https://, for example saltbushridgeestate.com.au.
In What type of website do you want?, choose Custom design using WithWine API/Widgets (eg: Wordpress).
Click Save. The Brand Id, Client Id and Client Secret only appear under Custom Credentials and Configuration after you click Save.
Copy the Client Secret straight away and keep it somewhere safe. WithWine only shows the Client Secret the first time you save.
If you lose the Client Secret, click Generate New Secret in Settings > Website, then enter the new Client Secret in WordPress.
Step 2: Download the plugin
In WithWine, go to Settings > Website > Wordpress Plugin.
Under Stable Releases, click Download Latest Stable Release. This downloads a file called withwine.zip.
Step 3: Upload the plugin to WordPress
In WordPress admin, go to Plugins > Add New > Upload Plugin.
Click Choose File and choose the withwine.zip file.
Click Install Now, then Activate Plugin.
Step 4: Connect the plugin to WithWine
In WordPress admin, go to Settings > WithWine.
Set Environment to Production.
Enter the Brand ID, Client ID and Client Secret Key. These are the Brand Id, Client Id and Client Secret from Step 1.
Click Save Changes.
Step 5: Check your permalinks
In WordPress admin, go to Settings > Permalinks.
Make sure you're not using the Plain structure. Post name works well.
Click Save Changes, even if you didn't change anything. This refreshes WordPress's links so the WithWine pages work.
What happens next
The plugin is ready to use. Next, set up your shop, product and checkout success pages. See "How to set up your shop, product and checkout success pages in WordPress".
The plugin may add Login, Register and Cart links to your menu automatically. See "How to add the cart, login and register links to your WordPress menu".
Troubleshooting
You can't see the Client Id or Client Secret: in Settings > Website, make sure What type of website do you want? is set to Custom design using WithWine API/Widgets (eg: Wordpress), then click Save.
WithWine shows a message about domain setup: using a domain you've bought needs some domain setup. Message WithWine support in the chat for help.
WithWine pages show "Page not found": go to Settings > Permalinks in WordPress, make sure the structure isn't Plain, and click Save Changes.
You need to reset the plugin settings: go to
/wp-admin/options-general.php?default_withwine_settingson your website. This sets every WithWine plugin setting back to its default.
