Announcement

  •  » Extensions
  •  » [resolved] Batch Downloader - Wrong Filename

#1 2012-08-28 10:53:28

photo_friend
Member
Berlin
1970-01-01
202

[resolved] Batch Downloader - Wrong Filename

Hello,

The Batch Downloader is a great plugin - thanks a lot. I have been looking a long time for something like this!!!!!

I discover just a error. The Filename in the archive are not always right. Looks like the plugin takes the photo title or description to create the filename instate the original file (look at the screenshot). If I download the photos manual one by one (without the Batch Downloader) everything works fine.

What can I do to avoid this error?

Thanks a lot - great job!

Offline

 

#2 2012-08-28 11:15:20

mistic100
Former Piwigo Team
Lyon (FR)
2008-09-27
3277

Re: [resolved] Batch Downloader - Wrong Filename

this is not really an error, let's explain

ZipArchive can't work with non ASCII chars, so if the photo name doesn't contains ASCII chars I use it for the filename (because it's more relevant than the random name generated by Piwigo)

if there are ASCII chars I don't have other choice to use the filename

Offline

 

#3 2012-08-28 11:44:15

photo_friend
Member
Berlin
1970-01-01
202

Re: [resolved] Batch Downloader - Wrong Filename

mistic100 wrote:

this is not really an error, let's explain

ZipArchive can't work with non ASCII chars, so if the photo name doesn't contains ASCII chars I use it for the filename (because it's more relevant than the random name generated by Piwigo)

if there are ASCII chars I don't have other choice to use the filename

Thanks for replay.
I think it is not the reason. All my pictures hat the same naming structure. I make a small documentation of the error with screenshots:

1) You can see the Photo in my piwigo gallery with the filename: 20080427_13-29-11-_MG_0737.jpg

2) You see the same photo in gallery preview this "photo title" - "Wonderful Spring"

3) I put 2 Photo in a collection to make the batch download

4) if you can see, the Batch Downloader use the "photo title" as news Filename instead the original Filename like as the second photo in the archive.

5) If I download the manual one by one with the standard function "Download this file" everything is as it should be - with the right filename.


In my opinien the Batch Downloader takes just the wrong field to create the filename in the archive.

Last edited by photo_friend (2012-08-28 11:48:20)

Offline

 

#4 2012-08-28 12:03:02

mistic100
Former Piwigo Team
Lyon (FR)
2008-09-27
3277

Re: [resolved] Batch Downloader - Wrong Filename

in your selection
the first picture (red trees) have it's filename as photo title
the second picture (white trees) have a proper photo title

In both case a take the photo title, don't see the problem

Offline

 

#5 2012-08-28 13:30:10

photo_friend
Member
Berlin
1970-01-01
202

Re: [resolved] Batch Downloader - Wrong Filename

mistic100 wrote:

in your selection
the first picture (red trees) have it's filename as photo title
the second picture (white trees) have a proper photo title

In both case a take the photo title, don't see the problem

Hi mistic100,

Thanks again for your quick response.
Now I see that we maybe have expectations of the requirements of the file download from a piwigo server. If I download a file or even a batch of files, I would like to have the original source file with the original filenames. In my case the filenames are: 20080427_13-29-11-_MG_0737.jpg and 20080427_13-19-26-_MG_0681.jpg.
If somebody downloads dozens or hundreds of photos, the filenames are always the most import way to manage photos on your local PC. Imagine you download hundreds of photos with different titles (no filenames), there is no way to handle the chaos with all the files on the local hard drive.

Maybe it could be a good idea to implement an option in the Batch Downloader plugin to let the administrator setup in the backend which information should be used as new Filename in the archive: the "Photo Title" or the original Filename:

Thanks so much for your support. The Batch Downloader is a great extension of piwigo.

Best Greetings
Hagen

Offline

 

#6 2012-09-03 11:09:17

mistic100
Former Piwigo Team
Lyon (FR)
2008-09-27
3277

Re: [resolved] Batch Downloader - Wrong Filename

version 1.0.3 always uses filenames

Offline

 

#7 2012-09-03 11:47:56

photo_friend
Member
Berlin
1970-01-01
202

Re: [resolved] Batch Downloader - Wrong Filename

mistic100 wrote:

version 1.0.3 always uses filenames

Great job!!! it works perfect!

Thanks a lot!

Offline

 

#8 2013-07-27 20:00:16

bob
Member
2013-07-26
6

Re: [resolved] Batch Downloader - Wrong Filename

mistic100 wrote:

version 1.0.3 always uses filenames

Looks like this has been changed in version 2 of Batch Downloader. It can easily be fixed, though. In main.inc.php change

Code:

$conf['batch_download']['file_pattern'] = isset($conf['batch_download_file_pattern']) ? $conf['batch_download_file_pattern'] : '%id%_%filename%_%dimensions%';

to

Code:

$conf['batch_download']['file_pattern'] = isset($conf['batch_download_file_pattern']) ? $conf['batch_download_file_pattern'] : '%filename%';

Last edited by bob (2013-07-27 20:00:41)

Offline

 

#9 2013-07-28 02:09:11

mistic100
Former Piwigo Team
Lyon (FR)
2008-09-27
3277

Re: [resolved] Batch Downloader - Wrong Filename

is think you didn't get the purpose of this line,

add $conf['batch_download_file_pattern'] = '%filename%'; in your local config and you will have the same result without modify any file (which is highly not recommended)


(it's quoted at the end of the configuration page)

Offline

 

#10 2014-01-03 16:43:16

Phil Good1
Guest

Re: [resolved] Batch Downloader - Wrong Filename

Bonjour,
J' ai le même problème que Bob avec le nom des images que l' on télécharge....
Je ne suis pas informaticien.... je bricole, je comprend bien qu'il y a un changement dans un fichier de config
mais je le trouve pas!
je fais actuellement des tests sur une configuration locale perso (Mac et Mamp), et je vois les fichiers PHP à travers 'netbeans.
PHP 5.4.4
ZipArchive 5.4.4

   Merci

 

#11 2014-01-03 16:47:59

mistic100
Former Piwigo Team
Lyon (FR)
2008-09-27
3277

Re: [resolved] Batch Downloader - Wrong Filename

Ceci est le forum anglais, merci d'aller sur le forum français (drapeau en haut à droite)

Offline

 

#12 2014-01-03 23:17:25

PhilGood
Guest

Re: [resolved] Batch Downloader - Wrong Filename

Finnally i find the solution by myself .......

           local/config/database.inc.php

   Paste :
$conf['batch_download_file_pattern'] = '%filename%';

and save !

    Thank you.

 

#13 2014-01-03 23:30:55

mistic100
Former Piwigo Team
Lyon (FR)
2008-09-27
3277

Re: [resolved] Batch Downloader - Wrong Filename

no no no no

database.inc is only for database logins

use LocalFilesEditor to edit the local configuration
see the doc http://piwigo.org/doc/doku.php?id=user_ … onf_locale

Offline

 

#14 2014-01-04 19:34:02

PhilGood
Guest

Re: [resolved] Batch Downloader - Wrong Filename

Thank you !
it's run !

 
  •  » Extensions
  •  » [resolved] Batch Downloader - Wrong Filename

Board footer

Powered by FluxBB

github twitter newsletter Donate Piwigo.org © 2002-2024 · Contact