aggregate.cgi: shorter filter
This commit is contained in:
@@ -107,17 +107,10 @@ s/\<\;span id\="\;calcms_title"\;\>\;[^\&]*\<\;\/span\>\;/\<span
|
|||||||
$list->{project_title} = '' unless defined $list->{project_title};
|
$list->{project_title} = '' unless defined $list->{project_title};
|
||||||
$content =~ s/(<(div|span)\s+id="calcms_title".*?>).*?(<\/(div|span)>)/$list->{project_title}/g;
|
$content =~ s/(<(div|span)\s+id="calcms_title".*?>).*?(<\/(div|span)>)/$list->{project_title}/g;
|
||||||
|
|
||||||
my $values = [];
|
my $title = join ' - ', grep {defined $_ and $_ ne ''} (
|
||||||
for
|
$list->{'series_name'}, $list->{'title'},
|
||||||
my $value ( $list->{'series_name'}, $list->{'title'}, $list->{'location'}, 'Programm ' . $list->{project_title} )
|
$list->{'location'}, 'Programm ' . $list->{project_title}
|
||||||
{
|
);
|
||||||
next unless defined $value;
|
|
||||||
next if $value eq '';
|
|
||||||
push @$values, $value;
|
|
||||||
}
|
|
||||||
|
|
||||||
my $title = join( ' - ', @$values );
|
|
||||||
|
|
||||||
$content =~ s/(<title>)(.*?)(<\/title>)/$1$title$3/;
|
$content =~ s/(<title>)(.*?)(<\/title>)/$1$title$3/;
|
||||||
|
|
||||||
$js = '';
|
$js = '';
|
||||||
|
|||||||
Reference in New Issue
Block a user