admin管理员组文章数量:1122832
I have a domain, for example tarikhema. I want to change WordPress default upload patch folder to another domain for example dtours. How can I do this?
My default folder is tarikhema/images/....
I want this: dtours/images/...
.
I have a domain, for example tarikhema.org. I want to change WordPress default upload patch folder to another domain for example dtours.net. How can I do this?
My default folder is tarikhema.org/images/....
I want this: dtours.net/images/...
.
- You can using WP Offload S3 or W3 Total Cache. Both examples are using AWS S3, there are probably other ways. But it's impossible to suggest anything without knowing how your domains are set up, if you're willing to use AWS, etc. – kero Commented Oct 16, 2017 at 8:44
2 Answers
Reset to default 0You can't do that. WordPress can store files only in its own uploads folder (or at least in the same root where the WordPress is installed. You can't upload files to remote website (different domain).
What you can do is to add the second domain as an alias to your main domain, and in that case, all URL's from the main domain will match the alias domain too.
JFI
We can do that by changing these two constant variables or can update from here as well.https://yourdomain.com/folder_name/wp-admin/options.php
Now find upload_path and change it to an absolute path of that folder where you want to upload images. after that find upload_url_path change it to the actual URL path and check once.
upload_path: /absolute/path/to/your/folder_name/wp-content/uploads
upload_url_path: https://yourdomain.com/folder_name/wp-content/uploads
本文标签: imagesChange wordpress default upload path to another domain
版权声明:本文标题:images - Change wordpress default upload path to another domain 内容由网友自发贡献,该文观点仅代表作者本人, 转载请联系作者并注明出处:http://www.betaflare.com/web/1736285701a1927514.html, 本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌抄袭侵权/违法违规的内容,一经查实,本站将立刻删除。
发表评论