MyBB Community Forums

Full Version: Parse error: syntax error
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
I have no idea why I am getting this error.

I get this message when I am on my forums index:

Parse error: syntax error, unexpected '-', expecting '}' in /home/u297512693/public_html/forum/global.php(504) : eval()'d code on line 65

Could someone please tell me what this means and how to solve this.

Thanks,
Grily
Can you post the contents of your "header" template here in [code] tags?
<div id="container">
		<a name="top" id="top"></a>
		<div id="header">
			<div class="logo"><a href="{$mybb->settings['bburl']}/index.php"><img src="{$theme['logo']}" alt="{$mybb->settings['bbname']}" title="{$mybb->settings['bbname']}" /></a></div>
			<div id="panel">{$welcomeblock}</div>
			<div class="clear"></div>
		</div>
		<div id="nav">
			<ul>
				<li><a href="{$mybb->settings['homeurl']}">Homepage</a></li>
				<li class="active"><a href="{$mybb->settings['bburl']}/index.php">Forum</a></li>
				<li><a href="{$mybb->settings['bburl']}/search.php">{$lang->toplinks_search}</a></li>
				<li><a href="{$mybb->settings['bburl']}/memberlist.php">{$lang->toplinks_memberlist}</a></li>
				<li><a href="{$mybb->settings['bburl']}/calendar.php">{$lang->toplinks_calendar}</a></li>
				<li><a href="{$mybb->settings['bburl']}/misc.php?action=help">{$lang->toplinks_help}</a></li>
			</ul>
			<div id="search">
				<form action="{$mybb->settings['bburl']}/search.php" method="post">
					<div class="search_input_wrap"><input name="keywords" class="search_input" title="Enter your search keywords" onfocus="if(this.value == 'Search...') {this.value='';}" onblur="if(this.value == '') {this.value='Search...';}" size="32" value="Search..." type="text" /></div>
					<input value="" name="submit-search" class="search_button" type="submit" />
					<input type="hidden" name="action" value="do_search" />
				</form>
			</div>
	                <div class="clear"></div>
		</div>
		<div id="content">

			<div id="breadcrumb">
				<div class="breadcrumb_left"><div class="breadcrumb_right">
					<ul>
						<li class="bread_home"><a href="{$mybb->settings['bburl']}/index.php" title="Home"></a></li>
						<navigation>
					</ul>
				</div></div>
			</div>

			<div id="sidebar">
				<a href="{$mybb->settings['bburl']}/misc.php?action=syndication" class="rss_button tip" target="_blank" title="Subscribe to our RSS feed"><div>{$lang->bottomlinks_syndication}</div></a>
				<div class="sidebar_block">
					<div class="sidebar_block_tcat"><strong>Menu</strong></div>
					<div class="sidebar_block_main">
						<ul>
							<li><a href="{$mybb->settings['homeurl']}">Fatal-Scape Homepage</a></li>
							<li><a href="http://fatal-scape.azok.org/forum/index.php">Fatal-Scape Forum</a></li>
							<li><a href="<archive_url>">{$lang->bottomlinks_litemode}</a></li>
							<li><a id="click" href="#" title="Toggle Width">Toggle theme width</a></li>
							<li><a href="{$mybb->settings['contactlink']}">{$lang->bottomlinks_contactus}</a></li>
						</ul>
					</div>
				</div>
				<div class="sidebar_block">
					<div class="sidebar_block_tcat"><strong>Advertise here:</strong></div>
					<div class="sidebar_block_main sidebar_block_pad">
						<center><a href="http://www.fatal-scape.azok.org/forum" title="Advertise Here"><img src="http://www.mohdrafi.com/wp-content/uploads/2007/06/banner200x200.gif" alt="Advertise here!" border="0" /></a></center>
					</div>
				</div>
			</div>
<div class="sidebar_block">
			<div id="main">
				{$pm_notice}
				{$bannedwarning}
				{$bbclosedwarning}
				{$unreadreports}
				{$pending_joinrequests}breadcrumb{$mybb-

^ Wtf, at the end the code just stops? Confused
That would be the problem Smile


You can try re-installing your theme, either that or here's the default MyBB header code:
	<div id="container">
		<a name="top" id="top"></a>
		<div id="header">
			<div class="logo"><a href="{$mybb->settings['bburl']}/index.php"><img src="{$theme['logo']}" alt="{$mybb->settings['bbname']}" title="{$mybb->settings['bbname']}" /></a></div>
			<div class="menu">
				<ul>
					<li><a href="{$mybb->settings['bburl']}/search.php"><img src="{$theme['imgdir']}/toplinks/search.gif" alt="" title="" />{$lang->toplinks_search}</a></li>
					<li><a href="{$mybb->settings['bburl']}/memberlist.php"><img src="{$theme['imgdir']}/toplinks/memberlist.gif" alt="" title="" />{$lang->toplinks_memberlist}</a></li>
					<li><a href="{$mybb->settings['bburl']}/calendar.php"><img src="{$theme['imgdir']}/toplinks/calendar.gif" alt="" title="" />{$lang->toplinks_calendar}</a></li>
					<li><a href="{$mybb->settings['bburl']}/misc.php?action=help"><img src="{$theme['imgdir']}/toplinks/help.gif" alt="" title="" />{$lang->toplinks_help}</a></li>
				</ul>
			</div>
			<hr class="hidden" />
			<div id="panel">
				{$welcomeblock}
			</div>
		</div>
		<hr class="hidden" />
		<br class="clear" />
		<div id="content">
			{$pm_notice}
			{$bannedwarning}
			{$bbclosedwarning}
			{$unreadreports}
			{$pending_joinrequests}
			<navigation>
			<br />
I've fixed the problem.
I made a copy of the theme, installed it.
Then I looked at the contents of the header and saw what was wrong.

Thank you, this can be locked.
This actually belongs in general support, too Smile

/moved