Previous Thread
Next Thread
Print Thread
Rate Thread
Joined: Nov 2001
Posts: 10,369
I type Like navaho
I type Like navaho
Joined: Nov 2001
Posts: 10,369
It's nothing that I ever really "wrote up" as it's so customized it'd be tough to post it as a mod.... and it was nothing that I really wanted to "support". However, it is easy to do.

Basically in the newpost.php & newreply.php script where it calls the .tmpl file - you add a clause so that if ($Board == "modifications") {
Then it calls a different template as well.
Like this:
Code
<br />		if ($Board == "modifications") {<br />		   	include("$thispath/templates/$tempstyle/newpostmod.tmpl");<br />		} else {<br />	   	include("$thispath/templates/$tempstyle/newpost.tmpl");<br />		}<br />


Then in addpost.php - I had to add some code near the top. Since our modification posting page basically builds a formatted subject and body - you need to use some code to build the subject & body however you want.

This is what I have near the top of the addpost.php file:
Code
<br />// ----- JoshPet's Mod Template START ---------<br />	$modname = get_input("modname","post");<br />	$moddesc = get_input("moddesc","post");<br />	$v60 = get_input("60","post");<br />	$v61 = get_input("61","post");<br />	$v62 = get_input("62","post");<br />	$v63 = get_input("63","post");<br />	$prerequisites = get_input("prerequisites","post");<br />	$author = get_input("author","post");<br />	$date = get_input("date","post");<br />	$credits = get_input("credits","post");<br />	$filesaltered = get_input("filesaltered","post");<br />	$databasealter = get_input("databasealter","post");<br />	$instructions = get_input("instructions","post");<br />	$status = get_input("status","post");<br />	$newfiles = get_input("newfiles","post");<br />	$modsubmit = get_input("modsubmit","post");<br /><br />if (($Board == "modifications") && ($modsubmit == "yes")) {<br /><br />  // --- Let's display the checked version numbers right --<br />  	if (($v60) && (($v61) || ($v62) || ($v63))) {<br />  		$version = $v60."-";<br />  	}	<br /><br />  	if (($v61) && (($v62) || ($v63))) {<br />  		$version .= $v61."-";<br />  	} else {<br />  		$version .= $v61;<br />  	}	<br /><br />  	if (($v62) && ($v63)) {<br />  		$version .= $v62."-";<br />  	} else {<br />  		$version .= $v62;<br />  	}<br />  	<br />  	if ($v63) {<br />  		$version .= $v63;<br />  	}<br />  	<br />  	if (!$version) {<br />  		$version = "$v60$v61$v62$v63";<br />  	}			<br />  <br /><br />  // --- Build Subject & Body ---------<br />	$Subject = "$status-[$version] $modname";<br />	$Body = "Mod Name / Version: $modname \n\n";<br />	$Body .= "Description: $moddesc \n\n";<br />	$Body .= "Working Under: UBB.Threads $version \n\n";<br />	$Body .= "Mod Status: $status \n\n";<br />	$Body .= "Any pre-requisites: $prerequisites \n\n";<br />	$Body .= "Author(s): $author \n\n";<br />	$Body .= "Date: $date \n\n";<br />	$Body .= "Credits: $credits \n\n";<br />	$Body .= "Files Altered: $filesaltered \n\n";<br />	$Body .= "New Files: $newfiles \n\n";<br />	$Body .= "Database Altered: $databasealter \n\n";<br />	$Body .= "Info/Instructions: $instructions \n\n";<br />	$Body .= "Disclaimer: Please backup every file that you intend to modify. \n";<br />	$Body .= "If the modification modifies the database, it's a good idea to backup your database before doing so. \n\n";<br />	$Body .= "Note: If you modify your UBB.Threads code, you may be giving up your right for \"official\" support from Infopop.";<br />	$Body .= "If you need official support, you'll need to restore unmodified files.  \n\n";<br />}<br />// ----- JoshPet's Mod Template END -----------<br />


That's not real specific - as it's tough to explain this like a generic mod - but hopefully it's enough to get you goin in the right direction.

Sponsored Links
Entire Thread
Subject Posted By Posted
Form for specific forum ericgtr 07/13/2003 6:17 AM
Re: Form for specific forum JoshPet 07/13/2003 6:53 AM
Re: Form for specific forum ericgtr 07/13/2003 7:19 AM
Re: Form for specific forum dimopoulos 07/14/2003 1:31 AM
Re: Form for specific forum Zackary 07/19/2003 9:00 AM
Re: Form for specific forum AKD96 07/19/2003 9:52 AM
Re: Form for specific forum DrChaos 09/16/2003 1:55 AM
Re: Form for specific forum DrChaos 12/31/2003 4:29 AM
Re: Form for specific forum omegatron 12/31/2003 5:33 AM
Re: Form for specific forum DrChaos 01/02/2004 2:26 AM
Re: Form for specific forum omegatron 01/02/2004 2:44 AM
Re: Form for specific forum DrChaos 01/02/2004 3:11 PM
Re: Form for specific forum omegatron 01/02/2004 5:11 PM
Re: Form for specific forum DrChaos 01/02/2004 10:46 PM
Re: Form for specific forum omegatron 01/02/2004 10:50 PM
Re: Form for specific forum DrChaos 01/02/2004 11:39 PM
Re: Form for specific forum Zackary 01/03/2004 2:21 AM
Re: Form for specific forum DrChaos 01/03/2004 3:23 AM
Re: Form for specific forum chillin 01/04/2004 7:05 PM
Re: Form for specific forum oceanwest 02/08/2004 10:41 PM
Re: Form for specific forum oceanwest 02/08/2004 10:42 PM
Re: Form for specific forum JoshPet 02/09/2004 9:29 AM
Re: Form for specific forum oceanwest 02/15/2004 8:12 PM
Re: Form for specific forum JoshPet 02/15/2004 10:25 PM
Re: Form for specific forum oceanwest 02/17/2004 4:47 AM
Re: Form for specific forum AKD96 05/13/2004 3:57 AM
Re: Form for specific forum AKD96 05/13/2004 4:00 AM
Re: Form for specific forum AKD96 05/13/2004 4:40 AM
Re: Form for specific forum AKD96 05/18/2004 10:31 PM
Re: Form for specific forum Zackary 05/19/2004 2:05 AM
Re: Form for specific forum AKD96 05/19/2004 4:19 AM
Re: Form for specific forum Zackary 05/19/2004 5:05 AM
Re: Form for specific forum AKD96 05/19/2004 6:26 AM
Re: Form for specific forum JoshPet 05/19/2004 9:50 AM
Re: Form for specific forum AKD96 05/19/2004 10:28 AM
Re: Form for specific forum JoshPet 05/19/2004 11:09 AM
Re: Form for specific forum scroungr 05/19/2004 1:35 PM
Re: Form for specific forum AKD96 05/19/2004 11:09 PM
Re: Form for specific forum Gregori 03/25/2005 4:50 PM
Re: Form for specific forum Gregori 04/14/2005 9:24 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:
Shock Hosting
Stable Host
bluehost
InterServer
Visit us on Facebook
Member Spotlight
Nettomo
Nettomo
Germany, Bremen
Posts: 417
Joined: November 2001
Forum Statistics
Forums63
Topics37,583
Posts293,955
Members13,824
Most Online151,614
Nov 14th, 2025
Today's Statistics
Currently Online 1424
Topics Created 0
Posts Made 0
Users Online 0
Birthdays 26
Top Posters
AllenAyres 21,080
JoshPet 10,369
LK 7,394
Lord Dexter 6,708
Gizmo 5,834
Greg Hard 4,625
Top Posters(30 Days)
Top Likes Received
isaac 82
Gizmo 20
Brett 7
WebGuy 2
Top Likes Received (30 Days)
None yet
The UBB.Developers Network (UBB.Dev/Threads.Dev) is ©2000-2026 VNC Web Services

 
Powered by UBB.threads™ PHP Forum Software 8.1.0
(Snapshot build 20260108)