MyBB Community Forums

Full Version: plugins.php
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Greetings,
I've been trying to install the Easy Install & Advanced Plugin,
to get The Cash Mod, but I ran into trouble.

I advedently did something wrong in the plugins.php, and ask that anyone help me out, and show me where I messed up.

[attachment=3090]

I have already placed to php codes in for Easy Install & Advanced Plugins,
and here's the error I get while trying to access the plugins page, via Admin CP.

Parse error: syntax error, unexpected T_ELSEIF in /usr/local/djcsites/dajoob.com/isr/forums/admin/plugins.php on line 45

I hope someone can help me, cause I really wanted this to work,
but I really don't know awhole lot about PHP, so I can't just scan
down through it and find my problem.

Regards,
_ISR_m3rc_
Check your modification regarding this part of the code:
	if($mybb->input['activate'])
if($mybb->input['force_readme'] == "yes"){ cpheader(); starttable(); tableheader("Please read the readme file before installing"); echo "<tr><td>"; echo "The creator of this plugin wishes for you to <a href=\"?action=readme&amp;plugin=".urlencode($codename).".php\" target=\"_blank\"><em>read the readme file</em></a> before installing this plugin.<br />\n"; echo "It will probably contain instructions on how to use the plugin, files you need to edit <strong>BEFORE</strong> activating the plugin, files to upload etc.<br/>\n"; echo "It is higly recommended you read the readme before continuing\n"; startform("plugins.php"); makehiddencode("action", "activate"); makehiddencode("activate", "1"); makehiddencode("plugin", $codename); makehiddencode("force_readme", "no"); echo "<br /><br /><div align=\"center\"><input type=\"submit\" value=\"I have read the readme, activate the plugin\">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<input type=\"submit\" value=\"Cancel Activation\" onClick=\"javascript:document.forms[0].action.value='';document.forms[0].submit()\"></div><br />\n"; endform(); echo "</td></tr>"; endtable(); cpfooter(); die(); }
	{
		$active_plugins[$codename] = $codename;
		$userfunc = $codename."_activate";
		$message = $lang->plugin_activated;
	}

I think you placed the modified code in the wrong place (perhaps you wanted it after the {