MyBB Community Forums

Full Version: Getting error
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Hello,

When I click on "View Today's Posts" on my site i get the following error.
Can someone please help me figure out the issue?

Parse error: syntax error, unexpected T_STRING, expecting '}' in /home/dano925/public_html/forum/search.php(600) : eval()'d code on line 9
have you modified anything recently in templates ..
You've got an error in your search_results_threads_thread template, review any edits you've made to this template recently or revert it to default.
can you please look this over and tell me if anything is out of place?


<tr>
<td align="center" class="{$bgcolor}" width="2%"><img src="{$theme['imgdir']}/{$folder}.gif" alt="{$folder_label}" title="{$folder_label}" /></td>
<td align="center" class="{$bgcolor}" width="2%">{$icon}</td>
<td class="{$bgcolor}">
{$attachment_count}
<div>
<span>{$prefix} {$gotounread}{$thread['threadprefix']}<a href="{$thread_link}{$highlight}" class="{$inline_edit_class} {$new_class}" id="tid_{$inline_edit_tid}">{$thread['subject']}</a>{$thread['multipage']}</span>
<span class="author smalltext">{$lang->Posted By:} {$thread['profilelink']}</span><br />{$thread['description']}
</div>
</td>
<td class="{$bgcolor}">{$thread['forumlink']}</td>
<td align="center" class="{$bgcolor}"><a href="javascript:MyBB.whoPosted({$thread['tid']});">{$thread['replies']}</a></td>
<td align="center" class="{$bgcolor}">{$thread['views']}</td>
<td class="{$bgcolor}" style="white-space: nowrap">
<span class="smalltext">
{$lastpostdate} {$lastposttime}<br />
<a href="{$thread['lastpostlink']}">{$lang->lastpost}</a>: {$lastposterlink}
</span>
</td>
{$inline_mod_checkbox}
</tr>
{$lang->Posted By:} is not how this should be used. The whole point of the $lang-> thing is that it's a variable, where the actual text to show is defined in a separate file. If you want to put some text in a template, don't use $lang-> unless you add a new language variable, just put the text in as text, i.e. take out {$lang->Posted By:} and just put Posted By:
why it is jMyBB.whoposted in below code ..
<a href="jMyBB.whoPosted({$thread['tid']});">{$thread['replies']}</a>

should be :
<a href="javascript:MyBB.whoPosted({$thread['tid']});">{$thread['replies']}</a>
thanks everyone that fixed my issues Smile