The website is for sale. Check here for more information.
This forum uses cookies
This forum makes use of cookies to store your login information if you are registered, and your last visit if you are not. Cookies are small text documents stored on your computer; the cookies set by this forum can only be used on this website and pose no security risk. Cookies on this forum also track the specific topics you have read and when you last read them. Please confirm whether you accept or reject these cookies being set.

A cookie will be stored in your browser regardless of choice to prevent you being asked this question again. You will be able to change your cookie settings at any time using the link in the footer.
Random display
(05-21-2014, 09:40 PM)Pirata Nervo Wrote: You also have them here:

I plan on finishing them yes but probably not within the next 30 days. I'm very very very busy and I prefer to spend my time developing MyBB rather than creating these tutorials (though they're definitely helpful IMO for new plugin developers, I believe they can wait 30 days Tongue)

30 days..... not if I can help itBig Grin
Oh boy....
* Diogo Parrinha runs
To download our paid plugins and receive support you must be a paid subscriber. Click here for more information.
(05-24-2014, 06:19 AM)Pirata Nervo Wrote: Oh boy....
* Pirata Nervo runs

You can't out run the internet Angel
Pirata Nervo says:

Though seriously now, I know you've got more pressing matter to attend to. (MyBB development takes precedence along with plugin development. And of course real life issues too.)
haha, that made me laugh. Yeah within a few weeks I'll be less busy!
To download our paid plugins and receive support you must be a paid subscriber. Click here for more information.
Looks like I may need some help with this plugin again.

I've made a fair bit of progress on things, though now it's only throwing this error:

Parse error: syntax error, unexpected '' (T_ENCAPSED_AND_WHITESPACE), expecting identifier (T_STRING) or variable (T_VARIABLE) or number (T_NUM_STRING) in mod_dev\index.php(400) : eval()'d code on line 29

When before it worked perfectly fine. I have no idea why it's pitching this error now. I'm not even sure where exactly in the code is causing problems because for me line 400 is:
$form = new Form("index.php?module=forum-randomplot&action=do_editplot", "post", "randomplot");

And line 29 is where I set the website url for the plugin info.

Here's the updated version of the plugin so you can have a look at the code.
The error is in mod_dev/index.php (line 400) - have you checked it?
To download our paid plugins and receive support you must be a paid subscriber. Click here for more information.
Line 400 of index.php is
eval("\$index = \"".$templates->get("index")."\";");

and around line 29 is:

// Load global language phrases

$logoutlink = $loginform = '';

if($mybb->user['uid'] != 0) {
eval("\$logoutlink = \"".$templates->get("index_logoutlink")."\";");
} else {
//Checks to make sure the user can login; they haven't had too many tries at logging in.

//Function call is not fatal

if(login_attempt_check(false) !== false) {
switch($mybb->settings['username_method']) {

case 0:
$login_username = $lang->login_username;

case 1:
$login_username = $lang->login_username1;

case 2:
$login_username = $lang->login_username2;

$login_username = $lang->login_username;

eval("\$loginform = \"".$templates->get("index_loginform")."\";");


But I'm not sure that this issue is there. I mean I haven't modified anything in the core mybb files. And I've only really made changes to this plugin.

And the index and plugin's front end function both worked at first (when I had the ACP stuff incorrectly set up. I had a section of code that should have been in randomplot_admin, outside of it... which was creating errors for the backend stuff. But the front end worked fine.)

Though I have no idea what's going on now because the issue is happening even if the plugin is disabled (by setting the global plugin disable in phpmyadmin and by renaming the plugin...)
The problem then is the 'index' template Smile (line 29)
To download our paid plugins and receive support you must be a paid subscriber. Click here for more information.
On the index template, around line 29 I had:
global $mybb, $db;
$query = $db->simple_select('rndm_plot', '*', 'disabled=0', array('order_by' => 'RAND()', 'limit' => 1));
$plot = $db->fetch_array($query);
$page =  $plot['theplot'];
echo $page;


Testing the base function.

After I removed that I was able to log in and stay logged in without the issue affecting me. (So it was likely what was affecting this... Though I'm not sure why it would cause an issue now, it wasn't causing problems before.)

And the plugin showed up as functioning.

But now there's a new issue... (well, it was happening before while I was developing the ACP stuff but I figured it was just because the ACP code wasn't done yet.)
Basically it drops me back to this screen when I try to click on the random plot link in the ACP.

I haven't made any adjustments to the plugin, given above, so whatever's causing this issue is in there. But I'm not sure where/what's causing it.

Users browsing this thread: 3 Guest(s)

About MyBB-Plugins

Plug Yourself into the best MyBB AddOn.

Copyright © 2009-2021 MyBB-Plugins Forums.


  • 51,000+ Posts
  • 19,000+ Members
  • 3,600+ Threads

Impressed? For sure
Check Full Stats here