Save photos in news post

Post

Posted
Rating:
#5196 (In Topic #1048)

Regarding the photos in news post, is it possible to auto save them in local server instead of remote URL once paste in the form & submitted ? at leaset you will have it on your server if the remote link removed .
 

Post

Posted
Rating:
#5197
Why not just attach the image. If you are using windows, in the explorer window just insert the http link to the image for the local path. This will automatically download the image to your computer and upload it.

Post

Posted
Rating:
Item has a rating of 5 Item has a rating of 5 Item has a rating of 5 Item has a rating of 5 Item has a rating of 5 (Liked by Adam Edington)
#5199
There is an unofficial feature for it that needs to be enabled manually in Commandr.

Go to Admin Zone > Tools > Commandr and enter this command exactly:

Code

:set_value('download_associated_media','1');
then:

Code

:mkdir(get_file_base().'/uploads/external_media');
then:

Code

clear_caches templates

You'll then find a new option has appeared on the posting forms that defaults to on, to download any images locally.

Post

Posted
Rating:
#5202
Thanks Chris,

Perfect done,
But the size of the photos are same as originals, most of them are guge !

Any chance to optimize or decrease them before it saves in /uploads/external_media folder ?

Post

Posted
Rating:
#5204
That's too much of an assumption for us to implement easily. If an admin is embedding a large desktop wallpaper for their users to download, it is very different from a naive user linking to a high-res digital camera image that doesn't need to be seen in full resolution.

It's hard to think how to approach that. We could implement a control on the UI to ask for the maximum size to resize to, but this makes things harder for the user for a feature that is meant to make things easier. We could add group settings for the size to resize to, but often the size you want is more to do with the situation than the permissions of the user posting it. We could not do the download if the size is too big. Neither of these seem perfect.

I suppose the best solution may be to change the download checkbox to a list with 4 options:
  1. Leave remote media as remote
  2. Download all remote media and limit maximum size to <configured maximum image size setting>
  3. Download all remote media smaller than <configured maximum image size setting> and leave the rest as remote
  4. Download all remote media and do not resize [option only there if you have a certain privilege]

I'll add a feature suggestion to the tracker.
1 guest and 0 members have recently viewed this.