Status
Not open for further replies.

Ludachris

New member
Got through the install, and just as it was going to finalize, it spit out a bbcode error. I did some googling and found you telling someone this on vb.org:
Additionally, the "Cannot redeclare handle_bbcode_video()" function is not an error with vBShout, it's with the [VIDEO] mod you have installed.
You need to contact the author of that mod and tell them this:
You need to wrap the handle_bbcode_video() function declaration in a if (!function_exists('handle_bbcode_video')) check.

I found the plugin code for the add-on what is causing this conflict. Here is the code:
function handle_bbcode_video(&$parser, $videoid, $videotitle)
{
global $vbulletin, $stylevar;

if (!$video = $vbulletin->db->query_first("SELECT video.*
FROM " . TABLE_PREFIX . "video AS video WHERE videoid = '" . $videoid . "'"))
{
$video['error'] = 'THIS VIDEO DOES NOT EXIST';
eval('$HTMLembed = "' . fetch_template('video_bbcode') . '";');
return $HTMLembed;
}

require_once(DIR . '/includes/functions_videodirectory.php');
require_once(DIR . '/includes/class_videosharingservice.php');
require_once(DIR . '/includes/videoserviceapi/class_' . strtolower($video['videoservice']) . '.php');

$classname = "vB_VideoSharingService_$video[videoservice]";
$obj = new $classname($vbulletin);

$showful = $vbulletin->options['videodirectory_showful'];
$showrel = $vbulletin->options['videodirectory_showrel'];
$showsta = $vbulletin->options['videodirectory_showsta'];

$video['embed'] = $obj->fetch_embedcode($video['videoidservice'], false, $showful, $showrel, $showsta);
$video['url'] = construct_video_url($video);
if (empty($videotitle)) { $videotitle = $video['title']; }

eval('$HTMLembed = "' . fetch_template('video_bbcode') . '";');
return $HTMLembed;
}
Can you help me form the IF statement to wrap that function?
 
PHP:
if (!function_exists('handle_bbcode_video')) { function handle_bbcode_video(&$parser, $videoid, $videotitle)

PHP:
return $HTMLembed; 
}
}
 
Status
Not open for further replies.

Similar threads

Legacy vBShout

vBulletin 3.8.x vBulletin 4.x.x
Seller
DragonByte Technologies
Release date
Last update
Total downloads
3,167
Customer rating
5.00 star(s) 1 ratings
Back
Top