Home › Forums › WordPress Plugins › Hide My WP › Conflict with Instant Images Plugin – Problem related to WP Rest API
- This topic has 3 replies, 2 voices, and was last updated 6 years, 5 months ago by Suman M..
-
AuthorPosts
-
July 17, 2018 at 2:23 pm #22623
Hi,
I’ve found a problem using hide_my_wp (v5.5.6) toghether with instant images plugin (v3.3.1).
I’m using the latest wordpress version (4.9.7) in multisite mode.
Hide_my_wp is network enabled and I’ve changed the/wp-content
url into/content
, from Hide_my_wp settings page.
I suspect that the problem could be related to the use of WP Rest API more than a simple conflict with instant images plugin.Instant Images is a plugin that let users import images from unsplash.com directly into the wordpress media library.
the plugin link is https://wordpress.org/plugins/instant-images/This plugins uses WP Rest API to import, resize, and move images into media library.
The problem is that during the import process the file path is processed by hide_my_wp and changes from
/public_html/wp-content/uploads/sites/2/instant-images/
/public_html/content/uploads/sites/2/instant-images/
and the process fails when the images is moved into meda library.Taking look at the plugin’s code it seems that the rewrite happens during a wp_send_json function located into
/instant-images/api/upload.phpReproducing the error is very simple
1. Activate hide_my_wp and change /wp-content into /content
2. Download and activate Instant Images plugin.
3. From the Dashboard, go to instant images settings page and try to import an imageThe import will failed and the browser console will show some warnings. Here you can se any post request where the file path appears modified.
Thanks in advance.
- This topic was modified 6 years, 5 months ago by virgodesign.
- This topic was modified 6 years, 5 months ago by virgodesign.
Attachments:
You must be logged in to view attached files.July 18, 2018 at 5:02 am #22632Suman M.Post count: 12478Hi, please do these:
– in General settings tab disable/uncheck “Directory List” and “Hide PHP Files” options
– in Permalinks & URLs tab, empty out “Ajax URL” field. Also empty out “API Base” and “API Query” fields (“API” option should be set to Enabled)
– if still the issue then try disabling “IDS” option in IDS Firewall tab.
Let us know. Thanks!
July 18, 2018 at 8:56 am #22634Hi Suman,
thanks for the reply.“Directory List”, “Hide PHP Files” and “IDS” options has been always disabled.
I’ve tried removing Ajax URL (that was “ajax”) and API Query ( that was “rest_route”) but the problem still persists.July 19, 2018 at 4:41 am #22639Suman M.Post count: 12478Hi, can you please let us know your site’s wp-admin login details as private reply so that we can look into the issue further.
-
AuthorPosts
You must be logged in to reply to this topic.