WP Media Folder Addon: OneDrive Personal Integration
1. Microsoft OneDrive Application Registration
The OneDrive integration is distributed as a separate addon. You need to install this add-on (plugin) in addition to WP Media Folder. The addon includes integration for Google Drive, Google Photo, Dropbox, OneDrive Business and Amazon S3 too.
First, you need a Microsoft Azure App to connect your website to a OneDrive Personal account. Go to https://portal.azure.com/, login and click on New registration button.
On Register an application form, setup an app name and copy your website URL into the Redirect URL field and click on the Register button.
At the Supported account types section, you should select "Accounts in any organizational directory (Any Azure AD directory - Multitenant) and personal Microsoft accounts (e.g. Skype, Xbox)" option.
You're almost done - from here you have an Application ID (Client ID), only the password is missing. On the left menu, go to Certificates & secrets, then click on the New client secret button to create one. After that, fill the Description and set the Expires for it.
A password (Client Secret) is generated right away after pressing on Add button; copy it because you will need it soon.
2. Login to OneDrive from WP Media Folder
Return to the WordPress dashboard and click on the menu Settings > WP Media Folder > Cloud > OneDrive tab > OneDrive Personal settings.
Please select your Media link type:
- Public link: generate a public accessible link for your files and affect the appropriate rights on the cloud files (Shared link)
- Private link: AJAX link, hide the cloud link to keep the original access right of your file (Users need a login to view the images)
After that, paste the following into the form fields:
- Client ID
- Client Secret
After that you save the configuration and hit the Connect OneDrive button.
You'll have to validate the access authorization to grant access to WordPress; just click Yes in the new window.
The connection should be a success ☺ If it is successful, you can create folders and sub-folders in OneDrive and in WP Media Folder - everything will be synchronized automatically!
3. How does it work? What can I do with OneDrive?
How does it work?
OneDrive can synchronize folders and sub-folders and files on your WP Media Folder interface and the same is possible the other way round (from WP Media Folder to OneDrive).
What are the sync directions?
It works in both directions! You can add a file to OneDrive and see it in WP Media Folder, or add a file in WP Media Folder and see it in OneDrive. It also means you can manage WP Media Folder files from your desktop using OneDrive sync software.
The WP Media Folder Onedrive integration allows you to perform 3 types of actions with your media:
- Import OneDrive media in WP Media Folder (works automatically after connection)
- Import OneDrive media into the WordPress media library
- Embed the OneDrive media in your content directly. In this case the media will be loaded into your content from OneDrive, not from your server.