You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I would love to be able redirect media references in a local environment to a corresponding production site. This would allow me to develop new features for an existing site without needing to download all of the sites /uploads directory. Basically what WordPress VIP allows with their local dev environment https://docs.wpvip.com/vip-local-development-environment/add-media-content/
Why
Developing features for an existing site is much easier if you can have an up-to-date copy of the site's database and media in the local environment. The database isn't usually too big, but the media can frequently be huge. Needing to download all of that for local development is a huge pain and takes up a lot of hard drive space. Just redirecting references to the local environment's uploads directory to the url of the existing production site lets you have access to the media in your local environment without needing to download everything.
How
To use the wpvip dev environment as an example, when an existing database is synced to a local dev environment, a search and replace is performed to replace references to the production site url with the url of the local environment. At this time, the user can define a media redirect URL—usually the url of the existing production site. If a reference to a media file in the local environment returns a 404—because the uploads directory wasn't downloaded—it will be redirected to the url provided by the user as the media redirect url, connecting it to the media hosted on the live production site.
The text was updated successfully, but these errors were encountered:
What
I would love to be able redirect media references in a local environment to a corresponding production site. This would allow me to develop new features for an existing site without needing to download all of the sites /uploads directory. Basically what WordPress VIP allows with their local dev environment https://docs.wpvip.com/vip-local-development-environment/add-media-content/
Why
Developing features for an existing site is much easier if you can have an up-to-date copy of the site's database and media in the local environment. The database isn't usually too big, but the media can frequently be huge. Needing to download all of that for local development is a huge pain and takes up a lot of hard drive space. Just redirecting references to the local environment's uploads directory to the url of the existing production site lets you have access to the media in your local environment without needing to download everything.
How
To use the wpvip dev environment as an example, when an existing database is synced to a local dev environment, a search and replace is performed to replace references to the production site url with the url of the local environment. At this time, the user can define a media redirect URL—usually the url of the existing production site. If a reference to a media file in the local environment returns a 404—because the uploads directory wasn't downloaded—it will be redirected to the url provided by the user as the media redirect url, connecting it to the media hosted on the live production site.
The text was updated successfully, but these errors were encountered: