Previous Thread
Next Thread
Print Thread
Rate Thread
#126479 07/08/2001 1:54 PM
Joined: Oct 2000
Posts: 49
Member
Member
Offline
Joined: Oct 2000
Posts: 49
Does anybody know about a hack to allow Admin or Mods to edit the title of a thread, before I reinvent the wheel?

Sponsored Links
Joined: May 2001
Posts: 6,708
Member
Member
Offline
Joined: May 2001
Posts: 6,708
Yes I know about the "edit Subject" hack. Did you check the V5 Database for it?

Joined: Oct 2000
Posts: 49
Member
Member
Offline
Joined: Oct 2000
Posts: 49
It's not in the database that I can find.

Where is this puppy?



);
}
----------------------------------------------------

Next, find:
----------------------------------------------------
Delete? To delete this post, check this box.
$WarningWords

----------------------------------------------------

Right AFTER it, add:
----------------------------------------------------
$SubjectEdit
----------------------------------------------------

Save the file and you are done!

Enjoy!
Joined: Dec 2000
Posts: 139
Member
Member
Offline
Joined: Dec 2000
Posts: 139
People need to do a SEARCH before asking for a hack!!!

##############################################################
# Edit Topic Subject
# Created By: Dave Downin ([email protected])
# http://www.arlo.net
#
# Last Updated: 07/04/00
##############################################################

What does it do?
* Allows the original poster, forum administrator or moderator
to change the subject of a message (by editing the first/original
message of a topic).
Tested on:
* This hack was created for UBB 5.45x
Make Backups of:
* postings.cgi

Install Instructions:


Open up postings.cgi and find:
----------------------------------------------------
if ($Name eq "TopicSubject") {
$TopicSubject = $Value;
$TopicSubject =~ s/<.+?>//g;
$TopicSubject = &UNHTMLIFY($TopicSubject);
}
----------------------------------------------------

Right AFTER it, add:
----------------------------------------------------
if ($Name eq "NewTopicSubject") {
$NewTopicSubject = $Value;
$NewTopicSubject =~ s/<.+?>//g;
$NewTopicSubject = &UNHTMLIFY($NewTopicSubject);
}
----------------------------------------------------

Next, find:
----------------------------------------------------
&Lock("lock.file");
open (POST, ">$ForumsPath/$ExactPath/$topic");
foreach $thisone(@revised) {
chomp($thisone);
print POST ("$thisonen");
}
close(POST);
&Unlock("lock.file");
----------------------------------------------------

REPLACE that with:
----------------------------------------------------
if ($NewTopicSubject ne $TopicSubject && $NewTopicSubject && $in{'ReplyNum'} eq "000000") {
$NewTopicSubject = &CensorCheck("$NewTopicSubject");
@stats = split(/||/,$revised[0]);
$stats[4] = $NewTopicSubject;
$revised[0] = "$stats[0]||$stats[1]||$stats[2]||$stats[3]||$stats[4]||$stats[5]||$stats[6]||$stats[7]";
}

&Lock("lock.file");
open (POST, ">$ForumsPath/$ExactPath/$topic");
foreach $thisone(@revised) {
chomp($thisone);
print POST ("$thisonen");
}
close(POST);
&Unlock("lock.file");

if ($NewTopicSubject ne $TopicSubject && $NewTopicSubject && $in{'ReplyNum'} eq "000000") {
&UpdateForumSummary($number, $topic);
}
----------------------------------------------------

Next, find:
----------------------------------------------------
print <----------------------------------------------------

Right BEFORE that, add:
----------------------------------------------------
if ($in{'ReplyNum'} eq "000000") {
$SubjectEdit = qq(

Subject:

Joined: Oct 2000
Posts: 49
Member
Member
Offline
Joined: Oct 2000
Posts: 49
Thanks mucho Prince!

Where did you find this, at Dave's?
I search the regular forums and the database, didn't see this hack...

Sponsored Links
Joined: May 2001
Posts: 6,708
Member
Member
Offline
Joined: May 2001
Posts: 6,708
He probably found it in the V5 Modifications forum. It would have been available at Dave's database since he coded it.


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
hatter
hatter
USA
Posts: 69
Joined: January 2001
Forum Statistics
Forums63
Topics37,573
Posts293,925
Members13,849
Most Online5,166
Sep 15th, 2019
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,833
Greg Hard 4,625
Top Posters(30 Days)
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-2024 VNC Web Services

 
Powered by UBB.threads™ PHP Forum Software 8.0.0
(Preview build 20221218)