Okay, I copied a tree of subdirectories to the galleries subdirectory, and tried my first Synchronization with the simulation box ticked.
The results are pasted in below.
Does this look about right in the eyes of the experts in this community ?
Database Synchronization With Files: ./Galleries/ [Simulation] Search for new images in the directories 26 albums added in the database 7433 photos added in the database 0 albums deleted in the database 0 photos deleted from the database 0 photos updated in the database 2382 errors during synchronization [Simulation] Metadata synchronization results 0 photos' information synchronized with files metadata 0 photos candidates for metadata synchronization Metadata used : filesize, width, height, date_creation, latitude, longitude List of errors
The list of 2382 errors will be left out.
It's pretty obvious that the problem is blank spaces in the name of each file. Screwed up in the nomenclature.
That correction is my homework assignment.
As for the rest, do these results look correct ?
===================ENVIRONMENT==============
Piwigo version: 2.8.3
PHP version: PHP: 5.5.36 [2016-12-20 16:27:32]
MySQL version: MySQL: 5.5.45-cll-lve [2016-12-20 16:27:32]
Piwigo URL: http://clintdanbury.info/pics/leaves/
Offline
Spaces are allowed, there must be another character that is not allowed. Post one example.
Offline
reddn wrote:
Spaces are allowed, there must be another character that is not allowed. Post one example.
nope by default no space is allowed ([Github] Piwigo file include/config_default.inc.php@L782) but _ are converted into space automatically
Offline
reddn wrote:
Post one example
flop25 wrote:
"...no space is allowed..."
"...but _ are converted into space automatically..."
Duh.
The (wrong) file names have hyphens, spaces, and underscore characters
2016-10-17-04-31-57 -- DSC_0638.JPG
I'm going to have to request shell access from my hosting company (they're okay with it, just being cautious; hardly blame them) so that I can run some command line stuff to fix the names.
I'm thinking that I'll just change all spaces to hyphens, and I suppose I'll change the underscore characters to hyphens as well.
Advice on that plan is welcome and requested.
Offline
flop25 wrote:
reddn wrote:
Spaces are allowed, there must be another character that is not allowed. Post one example.
nope by default no space is allowed ([Github] Piwigo file include/config_default.inc.php@L782) but _ are converted into space automatically
Geez, file Nazi's. Of all characters to not allow, that should be one to allow.
Turns out I added this in my LocalConfigEditor (under plugins) to allow for spaces in my file names.
$conf['sync_chars_regex'] = '/^[a-zA-Z0-9-_. ]+$/';
I personally do not remember changing the regex, but piwigo works just fine for me.
Note: I also use VideoJS with its synchronized feature using both mediainfo and ffmpeg (get a poster, and I add the film roll edges). It works with all of my video's, even ones that have spaces.
Clint, maybe you should change your allowed characters to allow for spaces. I have not had any problems but that doesn't mean you won't.
Last edited by reddn (2017-01-05 21:48:32)
Offline
So I change one line in the config file (whatever that is) and I don't have to worry about screwing up a thousand others ?
I will be Considering that carefully.
Offline
ClintDanbury wrote:
So I change one line in the config file (whatever that is) and I don't have to worry about screwing up a thousand others ?
I will be Considering that carefully.
Yep. But if it messes something up, you can go back start from scratch, which is where you are now anyway.
If you want to do it goto Admin > Plugins > (left dock) LocalFiles Editor > and add the above code on the line above the '?>'
Here is my LocalFiles Editor
<?php /* The file does not exist until some information is entered below. Once information is entered and saved, the file will be created. */ $conf['smtp_host']='smtp.gmail.com'; // Notice I didn't indicate the port $conf['smtp_port']='587'; $conf['smtp_user']='***@***.com'; $conf['smtp_password']='******'; $conf['smtp_secure']='tls'; // you can put ssl instead $conf['sync_chars_regex'] = '/^[a-zA-Z0-9-_. ]+$/'; $conf['newcat_default_status'] = 'private'; ?>
Offline
reddn wrote:
ClintDanbury wrote:
So I change one line in the config file (whatever that is) and I don't have to worry about screwing up a thousand others ?
I will be Considering that carefully.Yep. But if it messes something up, you can go back start from scratch, which is where you are now anyway.
no you just have to use your FTP access to edit it again
reddn wrote:
Here is my LocalFiles Editor
Code:
<?php /* The file does not exist until some information is entered below. Once information is entered and saved, the file will be created. */ $conf['smtp_host']='smtp.gmail.com'; // Notice I didn't indicate the port $conf['smtp_port']='587'; $conf['smtp_user']='***@***.com'; $conf['smtp_password']='******'; $conf['smtp_secure']='tls'; // you can put ssl instead $conf['sync_chars_regex'] = '/^[a-zA-Z0-9-_. ]+$/'; $conf['newcat_default_status'] = 'private'; ?>
here sync_chars_regex is what you need
Offline
A slight tangent, if you get shell access or before you upload again I found the detox program to be handy:
https://linux.die.net/man/1/detox
I also modified my default detoxrc to remove ~ as well.
jv
Offline