First make a backup of editpost.php before you continue
Created a template called: editpost_description
Add this to it:
(Note: remove the spaces in { secondaltcolor })
PHP Code:
<tr bgcolor="{ secondaltcolor }">
<td bgcolor="{ secondaltcolor }"><normalfont><b>Description:</b></normalfont></td>
<td bgcolor="{ secondaltcolor }"><normalfont><input type="text" class="bginput" name="description" value="$description" size="40" maxlength="85" tabindex="1"></normalfont></td>
</tr>
Save editpost_description.
Open editpost.php
Find:
PHP Code:
if ($getpost[postid]==$postid) {
$isfirst=1;
} else {
$isfirst=0;
}
if ($isfirst and $postinfo[title]=="" and $postinfo[dateline]+$editthreadtitlelimit*60>time()) {
$postinfo[title]=$threadinfo[title];
}
Replace it with:
PHP Code:
$description="";
$descriptionbit="";
if ($getpost[postid]==$postid) {
$isfirst=1;
$description=$threadinfo[description];
eval("\$descriptionbit = \"".gettemplate("editpost_description")."\";");
} else {
$isfirst=0;
}
if ($isfirst and $postinfo[title]=="" and $postinfo[dateline]+$editthreadtitlelimit*60>time()) {
$postinfo[title]=$threadinfo[title];
}
Find:
PHP Code:
if ($isfirst and $title!="" and $postinfo[dateline]+$editthreadtitlelimit*60>time()) {
$DB_site->query("UPDATE thread SET title='".addslashes(htmlspecialchars($title))."' WHERE threadid=$threadinfo[threadid]");
//$title="";
}
Replace it with:
PHP Code:
if ($isfirst and $postinfo[dateline]+$editthreadtitlelimit*60>time()) {
$DB_site->query("UPDATE thread SET description='".addslashes(htmlspecialchars($description))."' WHERE threadid=$threadinfo[threadid]");
if ($title!="") {
$DB_site->query("UPDATE thread SET title='".addslashes(htmlspecialchars($title))."' WHERE threadid=$threadinfo[threadid]");
//$title="";
}
}
Save and close
Open the template: editpost
Find:
(Note: there are spaces in { secondaltcolor })
PHP Code:
<tr>
<td bgcolor="{ secondaltcolor }" nowrap><normalfont><b>Subject:</b></normalfont></td>
<td bgcolor="{ secondaltcolor }"><normalfont><input type="text" class="bginput" name="title" value="$postinfo[title]" size="40" maxlength="85" tabindex="1"></normalfont></td>
</tr>
Under it add:
PHP Code:
$descriptionbit
Save the template and upload editpost.php
When your done it should like the attachment below, enjoy