EPrints Technical Mailing List Archive
See the EPrints wiki for instructions on how to join this mailing list and related information.
Message: #01328
< Previous (by date) | Next (by date) > | < Previous (in thread) | Next (in thread) > | Messages - Most Recent First | Threads - Most Recent First
[EP-tech] Bug in $doc.icon: size not allowed
- To: "'eprints-tech@ecs.soton.ac.uk'" <eprints-tech@ecs.soton.ac.uk>
- Subject: [EP-tech] Bug in $doc.icon: size not allowed
- From: John Salter <J.Salter@leeds.ac.uk>
- Date: Thu, 22 Nov 2012 18:03:32 +0000
Hi, EPrints-3.3.10 In ~/lib/defaultcfg/citations/eprint/summary_page.xml, the following expression is used: <epc:print expr="$doc.icon('HoverPreview','noNewWindow')}" /> This results in 'run_icon' being called from ~perl_lib/EPrints/Script/Compiled.pm, which in turn calls $doc->render_icon_link. render_icon_link allows a 'size' to be specified: $opts{size} = "small" unless defined $opts{size}; - but run_icon can not pass this value to the function call. Not quite sure how to fix it (brain shutting down for the day), Something like (in run_icon): foreach my $opt ( @opts ) { my $optv = $opt->[0]; if( $optv eq "HoverPreview" ) { $args{preview}=1; } elsif( $optv eq "noHoverPreview" ) { $args{preview}=0; } elsif( $optv eq "NewWindow" ) { $args{new_window}=1; } elsif( $optv eq "noNewWindow" ) { $args{new_window}=0; } + (PSEUDO-CODE) elsif( $optv in $config{thumbnail_types} ) $args{size}=$optv; } else { $self->runtime_error( "Unknown option to doc->icon(): $optv" ); } } Cheers, John
- Prev by Date: [EP-tech] Fwd: On OpenAIRE compatibility for UK repositories
- Next by Date: [EP-tech] OAI harvester questions
- Previous by thread: [EP-tech] Fwd: On OpenAIRE compatibility for UK repositories
- Next by thread: [EP-tech] OAI harvester questions
- Index(es):