MyBB Community Forums

Full Version: Global.php parse error after disabling codepress.
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Strange, I've never had to disable codepress before, but after doing so and editing the header template then saving (just changed a $lang variable) I get this error:

Parse error: syntax error, unexpected '<', expecting '}' in /MySite/global.php(527) : eval()'d code on line 10


I only changed literally 5 characters in the header template.
This leads to believe this may have been somehow caused by disabling codepress? yay or nay? what do you think? and I really would like to avoid doing a fresh install if possible.

Edit:
to be more specific the parse error shows on the forum where the header should be.

AH HA! Here's the line of code that caused it!! After removing it everything works again.
<li><a href="{$mybb->settings['bburl']}/usercp.php?action=usergroups"><img src="{$theme['imgdir']}/toplinks/memberlist.gif" alt="" title="" />{$lang->usergroups</a></li>
LOL WTF????
It wouldn't have anything to do with CodePress.

Can you please post the contents of your header template?
Thanks Nathan,
yea you're right, it wasn't codepress... it was this line of code:
<li><a href="{$mybb->settings['bburl']}/usercp.php?action=usergroups"><img src="{$theme['imgdir']}/toplinks/memberlist.gif" alt="" title="" />{$lang->usergroups</a></li>
Maybe it's the ?action=usergroups appended to the url or the .... oh snap... lmao... $lang is missing a closing curly bracket... damn.. hey thanks! lol

Edit:
Oh since you're here... what's the proper language variable for usercp language file's usergroups_joinable?
{$lang->usergroups_joinable} doesn't seem to work.
{$lang->usergroups_joinable}

It will only work in the User CP as that's where it's loaded.
ah, ok. Thank you. You know I've added $variables to the language php files manually before but it didn't seem enough to make them parse on their pages... is there another or a few more steps that need to be taken to properly add language variables so that they load on the desired MyBB pages? For example in Global.