MyBB Community Forums

Full Version: Paying for Custom Plugin!
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Pages: 1 2
I will need a custom Plugin for MyBB that will do this:

Http://manutdpeople.com needs a plugin that created a new page (manudtdpeople.com/live.php) and we can edit its content from the admin cp.

Basically we want a plugin that creates a new page called Live Streaming under /live.php but we have to be able to edit and put html code on the page in a easy way. I was thinking of having a sort of box were we can put in the html code and that it will show up on the live.php page. (sort of like template/stylesheet editing).

Besides that we also want a goldlive.php page with the same options as the live.php but only certain user groups can view that page (subscribers only).

Now we will use this plugin to stream live soccer matches for our members and subscribers but we want it to be integrated on a MyBB page with the option of having a ad free page for the subscribers and a ad page for the regular members.

Finally I was wondering if you could get this plugin done by end of Saturday or early Sunday since we will need it on Sunday if possible if not than its fine but we would love it to have it by Sunday. About the price we are willingly to pay for it just contact me on MSN or PM me Wink.

MSN: [email protected]

Thanks,
Bob
I advise you to contact Pirata Nervo (either here or at MyBB-plugins.com), he's very fast and excellent with what he does. I've worked with him a couple of times, and I've had no problems with the plugins so far.

EDIT: @Scoutie: I think he wants to be able to make updates feeds through the AdminCP, not just have a page with content (but it might be me not understanding Toungue)
You can update the content through the ACP anyways, though.
<?php
define("IN_MYBB", 1);
$templatelist = "live";
require_once './global.php';

eval("\$live_home = \"".$templates->get("live")."\";");
output_page($live_home);
?>

Create a template called "live", and add in a standard MyBB page (for an example, copy the "misc_help" template and remove the {$sections} variable - this is where you add the content).

Add the code to "live.php". Boom.
(2009-11-06, 10:10 PM)combus Wrote: [ -> ]I advise you to contact Pirata Nervo (either here or at MyBB-plugins.com), he's very fast and excellent with what he does. I've worked with him a couple of times, and I've had no problems with the plugins so far.

EDIT: @Scoutie: I think he wants to be able to make updates feeds through the AdminCP, not just have a page with content (but it might be me not understanding Toungue)
I already contacted him and he to to busy

(2009-11-06, 10:16 PM)Scoutie44 Wrote: [ -> ]You can update the content through the ACP anyways, though.

(2009-11-06, 10:21 PM)Tomm M Wrote: [ -> ]
<?php
define("IN_MYBB", 1);
$templatelist = "live";
require_once './global.php';

eval("\$live_home = \"".$templates->get("live")."\";");
output_page($live_home);
?>

Create a template called "live", and add in a standard MyBB page (for an example, copy the "misc_help" template and remove the {$sections} variable - this is where you add the content).

Add the code to "live.php". Boom.
But I want that some groups can access it and others no, how?
<?php
define("IN_MYBB", 1);

if($mybb->user['gid'] == x)
{
$templatelist = "live";
require_once './global.php';

eval("\$live_home = \"".$templates->get("live")."\";");
output_page($live_home);
}
else
{
$templatelist = "live_unreg";
require_once './global.php';

eval("\$live_home = \"".$templates->get("live_unreg")."\";");
output_page($live_home_unreg);
}
?>

Or something along those lines.
(2009-11-06, 10:23 PM)Zomaian Wrote: [ -> ]But I want that some groups can access it and others no, how?

if($mybb->usergroup['canmodcp'] || $mybb->usergroup['issupermod'] || $mybb->usergroup['cancp'])
{
     // User is a Moderator || Super Moderator || Administrator
}

if(!$mybb->user['uid'] || $mybb->user['usergroup'] == 8 || $mybb->user['usergroup'] == 11)
{
     // User is a guest, or members of group 8 or 11 - no permission
     error_no_permission();
}

Add something like that ABOVE the eval statement, but after global.php has been included.
Alright at the moment I have when people on my forum go to www.website.com/live.php it loads a template called "live" but only if you are a certain member. I got the following code:

<?php
define("IN_MYBB", 1);
$templatelist = "live";
require_once './global.php';

if($mybb->usergroup['canmodcp'] || $mybb->usergroup['issupermod'] || $mybb->usergroup['cancp'] || $mybb->user['usergroup'] == 9)
{
     // User is a Moderator || Super Moderator || Administrator || Subscriber
}

if(!$mybb->user['uid'] || $mybb->user['usergroup'] == 1 || $mybb->user['usergroup'] == 2 || $mybb->user['usergroup'] == 5 || $mybb->user['usergroup'] == 7)
{
     // User is a Guest || Registered || Awaiting Activation || Banned
     error_no_permission();
} 

add_breadcrumb("Watch Live", "live.php"); // (2)

eval("\$live_home = \"".$templates->get("live")."\";");
output_page($live_home);
?>

Now this works 100% perfect but now what I want to do is that if you are for example:
if($mybb->usergroup['canmodcp'] || $mybb->usergroup['issupermod'] || $mybb->usergroup['cancp'] || $mybb->user['usergroup'] == 9)
{
     // User is a Moderator || Super Moderator || Administrator || Subscriber
}
the template "goldlive" gets loaded.

and if you are:
if(!$mybb->user['uid'] || $mybb->user['usergroup'] == 1 || $mybb->user['usergroup'] == 2 || $mybb->user['usergroup'] == 5 || $mybb->user['usergroup'] == 7)
{
     // User is a Guest || Registered || Awaiting Activation || Banned
     error_no_permission();
} 
the template "live" gets loaded.

Basically I want it so if you are in a certain user group it loads a certain template in the live.php. I believe this is possible but I am horrible with PHP. Anyone care to help?

Thanks,
Bob
I got it with:

<?php
define("IN_MYBB", 1);
$templatelist = "live";
require_once './global.php';

if($mybb->user['usergroup'] == 6 || $mybb->user['usergroup'] == 3 || $mybb->user['usergroup'] == 4 || $mybb->user['usergroup'] == 9)
{
     // User is a Moderator || Super Moderator || Administrator || Subscriber
	 eval("\$goldlive_home = \"".$templates->get("goldlive")."\";");
	 output_page($goldlive_home);
}

if($mybb->user['uid'] || $mybb->user['usergroup'] == 1 || $mybb->user['usergroup'] == 2 || $mybb->user['usergroup'] == 5 || $mybb->user['usergroup'] == 7)
{
     // User is a Guest || Registered || Awaiting Activation || Banned
	 eval("\$live_home = \"".$templates->get("live")."\";");
     output_page($live_home);
} 

add_breadcrumb("Watch Live", "live.php"); // (2)
?>

Thanks for the help!
FYI, the following code:

if($mybb->user['uid'] || $mybb->user['usergroup'] == 1 || $mybb->user['usergroup'] == 2 || $mybb->user['usergroup'] == 5 || $mybb->user['usergroup'] == 7)
{
     // User is a Guest || Registered || Awaiting Activation || Banned
     eval("\$live_home = \"".$templates->get("live")."\";");
     output_page($live_home);
} 

Would probably be better as:

if(!$mybb->usergroup['canmodcp'] || !$mybb->usergroup['issupermod'] || !$mybb->usergroup['cancp'] || !$mybb->user['usergroup'] == 9)
{
     // User is anything but a Mod, Super Mod, Admin, or Subscriber
     eval("\$live_home = \"".$templates->get("live")."\";");
     output_page($live_home);
} 
Pages: 1 2