MyBB Community Forums

Full Version: build_prefeixes error in thread and search section
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Quote:Warning [2] Invalid argument supplied for foreach() - Line: 2573 - File: inc/functions.php PHP 5.2.17 (Linux)
File Line Function
/inc/functions.php 2573 errorHandler->error
/inc/functions.php 2606 build_prefixes
/search.php 1555 build_prefix_select
hey guys this message is all over my forums after upgrading from 1.6.3 to 1.6.4

even in creating thread
Warning [2] Invalid argument supplied for foreach() - Line: 2573 - File: inc/functions.php PHP 5.2.17 (Linux)
File	Line	Function
/inc/functions.php	2573	errorHandler->error
/inc/functions.php	2606	build_prefixes
/newthread.php	757	build_prefix_select


I think the problem is something wrong with my cache system , I rebuilt cache files but nothing changed .

What else do you think is the source of these errors
for any reason, have you kept a few files of old version (esp. functions.php, showthread.php, newthread.php) ..
nah that's not the case , I'm sure that its not about files , because all my files are genuine and no custom file is added unless the setting.php file. I suspect something is wrong with my setting or database configuration
Uh , I have no idea why here is so sacred and I love asking here and finding my answer on my own (out of the blue)

the format it says foreach and array got me thinking why the file forums/cache/threadprefixes.php
is a string ?! so I change the content and the $var into an array and dung ! everything is OK right now .


content of this file should be like this :
<?php

$threadprefixes = array (
);
 ?>