SMFHacks.com
SMF Store => Support => Bugs => Topic started by: shuban on April 17, 2014, 05:43:15 pm
-
2: Invalid argument supplied for foreach()
File: .../public_html/Themes/default/index.template.php
Line: 1494
It corresponds to this:
// Create the buttons...
foreach ($button_strip as $key => $value)
{
How do I fix this?
-
It would be part of any store calls that say DoToolBarStrip normally means you aren't passing buttons/it is empty the button array you are passing.
-
True, but how do I stop it from coming up?
-
You would need to trace where it is coming from. If it is item view would be in the template_viewitem function
-
It's this one:
<div itemscope="itemscope" itemtype="http://data-vocabulary.org/Product">
<table border="0" cellpadding="0" cellspacing="0" align="center" width="90%">
<tr>
<td style="padding-right: 1ex;" align="right" >
<table cellpadding="0" cellspacing="0" align="right">
<tr>
', DoToolBarStrip($context['store']['buttons_item'], 'bottom'), '
</tr>
</table>
</td>
</tr>
I know because when I delete it, the error goes away. But I can't just delete it... What can I do with it?
-
You probably removed something above $context['store']['buttons_item']
Is what sets that up.