2011-05-31, 11:28 PM
Hey! Check out this: http://setupwith.us/showthread.php?tid=4...132#pid132 at the top I get a error with my plugin installed, I was wondering if you could look through it and tell me what I'm doing wrong, thanks.
Code:
Code:
Quote:<?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("postbit", "future_postbit");
function random_future_info()
{
return array(
'name' => 'Random Future',
'description' => 'Give your future a spice!',
'website' => 'http://www.setupwith.us',
'author' => 'Daniel Watts',
'authorsite' => 'http://www.setupwith.us',
'version' => '1.0',
"guid" => "",
"compatibility" => "*"
);
}
function random_future_activate()
{
global $mybb, $templates;
require_once MYBB_ROOT."/inc/adminfunctions_templates.php";
find_replace_templatesets("postbit_author_user", '#inglevel\']}#', 'inglevel\']}<br />Random Future:');
rebuild_settings();
}
function random_future_deactivate()
{
global $mybb, $templates;
require "../inc/adminfunctions_templates.php";
find_replace_templatesets("postbit_author_user", '#<br />Random Future:#', '',0);
rebuild_settings();
}
?>