2009-07-23, 10:02 AM
That's my first plugin, so I don't have enough knowledge about it.
How to add string in forums list and topics list?
I want to add an user avatar on that pages, near the "last post title/user" text. Just like on this forum http://www.gamesboard.pl/
I made same core of that plugin:
But nothing is showing.
What do I do wrong?
How to add string in forums list and topics list?
I want to add an user avatar on that pages, near the "last post title/user" text. Just like on this forum http://www.gamesboard.pl/
I made same core of that plugin:
<?php
// Disallow direct access to this file for security reasons
if(!defined("IN_MYBB"))
{
die("Direct initialization of this file is not allowed.<br /><br />Please make sure IN_MYBB is defined.");
}
$plugins->add_hook("build_forumbits_forum", "lastPosterAvatar_add");
function lastPosterAvatar_info()
{
return array(
"name" => "Last Poster Avatar",
"description" => "A sample plugin that show a avatar of last poster - on forum index and threds list.",
"website" => "http://www.mybboard.pl",
"author" => "BlueMan",
"authorsite" => "http://www.blueman.pl",
"version" => "0.0001",
"guid" => "",
"compatibility" => "*"
);
}
function lastPosterAvatar_activate()
{
}
function lastPosterAvatar_deactivate()
{
}
function lastPosterAvatar_add($forum)
{
$forum['lastAvatar'] = 'Test->';
//eval("\{$forum['lastAvatar']} .= \"adfadfad\";");
}
?>
And in forumbit_depth1_forum_lastpost template I have add {$forum['lastAvatar']}.But nothing is showing.
What do I do wrong?