Changeset 23561 for main/trunk/greenstone2/perllib/plugins/BasePlugin.pm
- Timestamp:
- 2011-01-13T11:49:38+13:00 (13 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
main/trunk/greenstone2/perllib/plugins/BasePlugin.pm
r23544 r23561 382 382 } 383 383 384 sub block_filename385 {386 my $self = shift(@_);387 my ($block_hash,$filename) = @_;388 389 if ($ENV{'GSDLOS'} =~ m/^windows$/) {390 391 # lower case the entire thing, eg for cover.jpg when its actually cover.JPG392 my $lower_filename = lc($filename);393 $block_hash->{'file_blocks'}->{$lower_filename} = 1;394 # my $lower_drive = $filename;395 # $lower_drive =~ s/^([A-Z]):/\l$1:/i;396 397 # my $upper_drive = $filename;398 # $upper_drive =~ s/^([A-Z]):/\u$1:/i;399 #400 # $block_hash->{'file_blocks'}->{$lower_drive} = 1;401 # $block_hash->{'file_blocks'}->{$upper_drive} = 1;402 }403 else {404 $block_hash->{'file_blocks'}->{$filename} = 1;405 }406 }407 384 408 385 # rename imported files and assoc files using URL encoding by default … … 441 418 442 419 if ($self->{'block_exp'} ne "" && $filename_full_path =~ /$self->{'block_exp'}/) { 443 $self->block_filename($block_hash,$filename_full_path);420 &util::block_filename($block_hash,$filename_full_path); 444 421 } 445 422 … … 461 438 } 462 439 if (&util::fd_exists($coverfile)) { 463 $self->block_filename($block_hash,$coverfile);440 &util::block_filename($block_hash,$coverfile); 464 441 } 465 442 }
Note:
See TracChangeset
for help on using the changeset viewer.