Lionel
11-20-2004, 12:00 PM
I have upgraded the init.php with the new permissions by swapping it with the old ones, did the database upgrade. Now when I try to edit a category, it does not update permissions and it tells me:
Warning: Invalid argument supplied for foreach()
in includes/functions.php on line 2931
which is:
// takes a bitfield and the array describing the resulting fields
function convert_bits_to_array(&$bitfield, $_FIELDNAMES)
{
$bitfield = intval($bitfield);
$arry = array();
foreach ($_FIELDNAMES AS $field => $bitvalue)
{
if ($bitfield & $bitvalue)
{
$arry["$field"] = 1;
}
else
{
$arry["$field"] = 0;
}
}
return $arry;
}
Warning: Invalid argument supplied for foreach()
in includes/functions.php on line 2931
which is:
// takes a bitfield and the array describing the resulting fields
function convert_bits_to_array(&$bitfield, $_FIELDNAMES)
{
$bitfield = intval($bitfield);
$arry = array();
foreach ($_FIELDNAMES AS $field => $bitvalue)
{
if ($bitfield & $bitvalue)
{
$arry["$field"] = 1;
}
else
{
$arry["$field"] = 0;
}
}
return $arry;
}