Previous Thread
Next Thread
Print Thread
Rate Thread
Joined: May 2000
Posts: 125
Member
Member
Offline
Joined: May 2000
Posts: 125
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.


Sponsored Links
Entire Thread
Subject Posted By Posted
Carriage Returns and HTML Derek 04/04/2001 7:33 PM
Re: Carriage Returns and HTML dgermann 04/05/2001 2:32 AM
Re: Carriage Returns and HTML Sharif 04/05/2001 9:55 AM
Re: Carriage Returns and HTML Derek 04/06/2001 2:28 AM
Re: Carriage Returns and HTML Sharif 04/06/2001 11:46 AM
Re: Carriage Returns and HTML Derek 04/11/2001 5:51 AM
Re: The answer will come from Scream! Sharif 04/11/2001 11:46 AM
Re: The answer will come from Scream! Derek 04/11/2001 8:20 PM

Link Copied to Clipboard
Donate Today!
Donate via PayPal

Donate to UBBDev today to help aid in Operational, Server and Script Maintenance, and Development costs.

Please also see our parent organization VNC Web Services if you're in the need of a new UBB.threads Install or Upgrade, Site/Server Migrations, or Security and Coding Services.
Recommended Hosts
We have personally worked with and recommend the following Web Hosts:
Stable Host
bluehost
InterServer
Visit us on Facebook
Member Spotlight
isaac
isaac
California
Posts: 1,157
Joined: July 2001
Forum Statistics
Forums63
Topics37,575
Posts293,931
Members13,823
Most Online6,139
Sep 21st, 2024
Today's Statistics
Currently Online
Topics Created
Posts Made
Users Online
Birthdays
Top Posters
AllenAyres 21,079
JoshPet 10,369
LK 7,394
Lord Dexter 6,708
Gizmo 5,834
Greg Hard 4,625
Top Posters(30 Days)
Gizmo 1
Top Likes Received
isaac 82
Gizmo 20
Brett 7
WebGuy 2
Morgan 2
Top Likes Received (30 Days)
None yet
The UBB.Developers Network (UBB.Dev/Threads.Dev) is ©2000-2025 VNC Web Services

 
Powered by UBB.threads™ PHP Forum Software 8.0.1
(Snapshot build 20240918)