You need to hack w3t.pm to take out auto linebreaks
Comment line 63 : $value =~ s/\n/<BR>/g;
And line 127 : $body =~ s/\n/<BR>/g;
You need too a small hack in editpost.pl such that undo_markup shouldn't be called when HTML is enabled for a forum.
Add a query before calling undo_mark: (around line 141 in editpost.pl)
my $Board_q = $dbh -> quote($Board);
$query = qq!
SELECT
Bo_HTML
FROM w3t_Boards
WHERE Bo_Keyword = $Board_q
!;
$sth = $dbh -> prepare ($query) or w3t::not_right("Query syntax error: $DBI::errstr. Query: $query",$Cat,1);
$sth -> execute() or w3t::not_right("Can't execute query: $query. Reason: $DBI::errstr",$Cat,1);
my ($HTML) = $sth -> fetchrow_array;
$sth -> finish;
Then do the necessary changes such that yoy get:
$Body = w3t::undo_markup($Body) [:red]unless ($HTML eq "On");
$Body =~s /< br >/\ n/gi [:red]unless ($HTML eq "On")[/b];
This is not a complete satisfactory hack (when you edit a post, you'll see the HTML
tags instead of invisible carriage returns) but it works fine to display the HTMl documents.