User regi date and number of posts
Rushian 0
From: -
From: -
Notice
This topic is archived. New comments cannot be posted and votes cannot be cast.Responses to this topic
1 Re: User regi date and number of posts
Rushian
OP
0
From: -
From: -
User regi date and number of posts
Nice. Thanks!
Nice. Thanks!
1 Re: User regi date and number of posts
Philipp
From: Vienna, Austria
Administrator
1340From: Vienna, Austria
User regi date and number of posts
Here the modified template:
Here the modified template:
<?php
global $insert;
$username = addslashes($insert[post_author]);
$query = DBQuery("SELECT * FROM esselbach_st_users WHERE user_name = '$username'");
$userdata = mysql_fetch_array($query);
if ($userdata[user_posts] < 5) $ustatus = "<font color = "blue">Junior Member</font>";
if ($userdata[user_posts] > 4) $ustatus = "<font color = "green">Member</font>";
if ($userdata[user_posts] > 100) $ustatus = "<font color = "red">Senior Member</font>";
if ($insert[post_astatus]) $ustatus = "<font color = "yellow">Moderator</font>";
$uposts = "<b>Posts:</b> $userdata[user_posts]";
$rt = explode(" ",$userdata[user_regtime]);
$ujoin = "<b>Joined:</b> $rt[0]";
$memno = "<b>Member No.:</b> $userdata[user_id]";
if ($userdata[user_location]) $ulocation = "<b>From:</b> $userdata[user_location]";
$EST_TEMPLATE = <<<TEMPLATE
<!-- Template forum_thread_post -->
<tr>
<td bgcolor="#6b85aa">
<a href="https://www.contentteller.com/post.php?action=delete&id=$insert[post_id]">
<img src="https://www.contentteller.com/images/delete.gif" title="Delete Posting (Admin only)" border="0" align="right" /></a>
<a href="https://www.contentteller.com/post.php?action=plonk&id=$insert[post_id]">
<img src="https://www.contentteller.com/images/plonk.gif" title="Plonk Posting (Admin only)" border="0" align="right" /></a>
<a href="https://www.contentteller.com/post.php?action=solved&id=$insert[post_id]">
<img src="https://www.contentteller.com/images/solution.gif" title="Mark As Solution (Topic Starter only)" border="0" align="right" /></a>
<a href="https://www.contentteller.com/postprint$insert[post_id].html">
<img src="https://www.contentteller.com/images/printer.gif" title="Print Posting" border="0" align="right" /></a>
<a href="https://www.contentteller.com/post.php?action=quote&id=$insert[post_id]"">
<img src="https://www.contentteller.com/images/quote.gif" title="Quote Posting" border="0" align="right" /></a>
<a href="https://www.contentteller.com/post.php?action=edit&id=$insert[post_id]">
<img src="https://www.contentteller.com/images/edit.gif" title="Edit Posting" border="0" align="right" /></a>
<font face="Verdana, Arial" size="2" color="#FFFFFF"><b>$insert[post_author]</b></font>
<font face="Verdana, Arial" size="1" color="#FFFFFF"><b>($ustatus)</b></font>
<a href="https://www.contentteller.com/profile.php?user=$insert[post_authorlink]">
<img src="https://www.contentteller.com/images/profile.png" title="View Profile" border="0" /></a><br />
<font face="Verdana, Arial" size="1" color="#FFFFFF">$uposts $ulocation $ujoin $memno</font>
</td>
</tr>
<tr>
<td bgcolor="#bbc3dd">
<font face="Verdana, Arial" size="1">
<img src="https://www.contentteller.com/images/icons/$insert[post_icon]" border="0" align="left">
Posted - $insert[post_time]
</font>
</td>
</tr>
<tr>
<td bgcolor="#ffffff">
<font face="Verdana, Arial" size="2">
$insert[post_text]
</font>
<p align="right">
<font face="Verdana, Arial" size="1">
<a name="$insert[post_id]"></a><a href="#$insert[post_id]"><b>Post #$insert[post_id]</b></a>
</font>
</p>
</td>
</tr>
TEMPLATE;
?>
How do I get the user regi date and number of posts into the forum_thread_post template like I've seen on the NT Compatible website.