# #
# File: shared/Template/Posting.pm #
# #
-# Authors: Andre Malo <nd@o3media.de>, 2001-06-16 #
+# Authors: André Malo <nd@o3media.de> #
# #
# Description: show HTML formatted posting #
# #
use strict;
use vars qw(
@EXPORT
- $VERSION
);
use Encode::Posting;
#
# Version check
#
-$VERSION = do { my @r =(q$Revision$ =~ /\d+/g); sprintf "%d."."%02d" x $#r, @r };
+# last modified:
+# $Date$ (GMT)
+# by $Author$
+#
+sub VERSION {(q$Revision$ =~ /([\d.]+)\s*$/)[0] or '0.0'}
################################################################################
#
#
# Return: -none-
#
-sub print_posting_as_HTML ($$$) {
+sub print_posting_as_HTML ($$$;$) {
my ($threadpath, $tempfile, $param) = @_;
my $template = new Template $tempfile;
my $assign = $param -> {assign};
+ my $show_deleted = $param->{showDeleted};
my $view = get_view_params ({
adminDefault => $param -> {adminDefault}
else {
my ($mnode, $tnode) = get_message_node ($xml, 't'.$param -> {thread}, 'm'.$param -> {posting});
- unless ($mnode and not $mnode->getAttribute('invisible')) {
+ # do not show if not wanted
+ if(!$mnode || ($mnode->getAttribute('invisible') && !$show_deleted)) { # and not $mnode->getAttribute('invisible')) {
print ${$template -> scrap (
$assign -> {errorDoc},
{ $assign -> {errorText} => $template -> insert ($assign -> {'notAvailable'}) }
#
#
-### end of Template::Posting ###################################################
\ No newline at end of file
+### end of Template::Posting ###################################################