Dismounted I saw some of your post like you said including
this
Anyway this is what I have so far.
Dropped into "bbcode_create"
PHP Code:
require_once(DIR . '/includes/bbcode_user.php');
Dropped into "bbcode_fetch_tags"
PHP Code:
$tag_list['no_option'][user] = array(
'callback' => 'handle_external',
'strip_empty' => true,
'external_callback' => 'bbcode_user'
);
and this is the php file
EDIT*****
PHP Code:
<?php
require_once('./global.php');
require_once(DIR . '/includes/class_bbcode.php');
require_once(DIR . '/includes/functions_user.php');
function bbcode_user(&$parser, $value)
{
$fetchuser = $db->query('
SELECT displaygroupid, username, userid
FROM ' . TABLE_PREFIX . 'user
WHERE username = '$value'
');
if ($user = $db->fetch_array($fetchuser))
{
fetch_musername($user);
$name = '<a href="member.php?' . $vbulletin->session->vars['sessionurl'] . "u=$user[userid]\">$user[musername]</a>";
return $name;
}
}
?>
I am getting error when I click "BB code Manager"
Quote:
Fatal error: Call to a member function clean_array_gpc() on a non-object in *****\www\Forums\global.php on line 22
|
and I get this when I use the bbcode in a post:
EDIT**********
Quote:
Parse error: parse error, unexpected T_VARIABLE in ****\www\Forums\includes\bbcode_user.php on line 10
|
Any help would be awesome!