projects
/
matthijs
/
upstream
/
blosxom-plugins.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Convert tagcloud and uf plugins to multi-line %config initialisation, for better...
[matthijs/upstream/blosxom-plugins.git]
/
general
/
interpolate_conditional
diff --git
a/general/interpolate_conditional
b/general/interpolate_conditional
index 02130ba70b34130e1211696498fece6721c0994b..264695bedfcb900980efcbed922062cc7e06737d 100644
(file)
--- a/
general/interpolate_conditional
+++ b/
general/interpolate_conditional
@@
-22,25
+22,25
@@
sub interpolate {
my $template = shift;
# defined
my $template = shift;
# defined
- $template =~ s#\?\{(\$\w+(?:::
)?\w
*) (.*?)\}#"defined $1 ? \$2 : ''"#gee;
+ $template =~ s#\?\{(\$\w+(?:::
\w+)
*) (.*?)\}#"defined $1 ? \$2 : ''"#gee;
# not defined
# not defined
- $template =~ s#\?\{!(\$\w+(?:::
)?\w
*) (.*?)\}#"!defined $1 ? \$2 : ''"#gee;
+ $template =~ s#\?\{!(\$\w+(?:::
\w+)
*) (.*?)\}#"!defined $1 ? \$2 : ''"#gee;
# not equal to
# not equal to
- $template =~ s#\?\{(\$\w+(?:::
)?\w
*)!=(.*?) (.*?)\}#"defined $1 and $1 ne '$2' ? \$3 : ''"#gee;
+ $template =~ s#\?\{(\$\w+(?:::
\w+)
*)!=(.*?) (.*?)\}#"defined $1 and $1 ne '$2' ? \$3 : ''"#gee;
# equal to
# equal to
- $template =~ s#\?\{(\$\w+(?:::
)?\w
*)=(.*?) (.*?)\}#"defined $1 and $1 eq '$2' ? \$3 : ''"#gee;
+ $template =~ s#\?\{(\$\w+(?:::
\w+)
*)=(.*?) (.*?)\}#"defined $1 and $1 eq '$2' ? \$3 : ''"#gee;
# greater than
# greater than
- $template =~ s#\?\{(\$\w+(?:::
)?\w
*)>(.*?) (.*?)\}#"defined $1 and $1 gt '$2' ? \$3 : ''"#gee;
+ $template =~ s#\?\{(\$\w+(?:::
\w+)
*)>(.*?) (.*?)\}#"defined $1 and $1 gt '$2' ? \$3 : ''"#gee;
# less than
# less than
- $template =~ s#\?\{(\$\w+(?:::
)?\w
*)<(.*?) (.*?)\}#"defined $1 and $1 lt '$2' ? \$3 : ''"#gee;
+ $template =~ s#\?\{(\$\w+(?:::
\w+)
*)<(.*?) (.*?)\}#"defined $1 and $1 lt '$2' ? \$3 : ''"#gee;
# unconditional (and recursive)
# unconditional (and recursive)
- while( $template =~ s/(\$[a-zA-Z]\w+(?:::
)?\w
*)/"defined $1 ? $1 : ''"/gee ) { }
+ while( $template =~ s/(\$[a-zA-Z]\w+(?:::
\w+)
*)/"defined $1 ? $1 : ''"/gee ) { }
return $template;
return $template;
@@
-118,20
+118,23
@@
Drop the interpolate_conditional plug-in into your Blosxom plugins folder.
Rael Dornfest <rael@oreilly.com>, http://www.raelity.org/
Rael Dornfest <rael@oreilly.com>, http://www.raelity.org/
+This plugin is now maintained by the Blosxom Sourceforge Team,
+<blosxom-devel@lists.sourceforge.net>.
+
=head1 ACKNOWLEDGEMENTS
Eric David Sherman, for < and >
=head1 SEE ALSO
=head1 ACKNOWLEDGEMENTS
Eric David Sherman, for < and >
=head1 SEE ALSO
-Blosxom Home/Docs/Licensing: http://
www.raelity.org/apps/blosxom
/
+Blosxom Home/Docs/Licensing: http://
blosxom.sourceforge.net
/
-Blosxom Plugin Docs: http://
www.raelity.org/apps/blosxom/plugin.s
html
+Blosxom Plugin Docs: http://
blosxom.sourceforge.net/documentation/users/plugins.
html
=head1 BUGS
=head1 BUGS
-Address bug reports and comments to the Blosxom mailing list
-
[http://www.yahoogroups.com/group/blosxom]
.
+None known; please send bug reports and feedback to the Blosxom
+
development mailing list <blosxom-devel@lists.sourceforge.net>
.
=head1 LICENSE
=head1 LICENSE