Seite 1 von 1

Problem mit Link Categorie

Verfasst: 26.06.2005 17:07
von ...:::Stulle:::...
Hallo,

ich bekomme folgende Fehlermeldung im Adminbereich, auf der linken Seite, wo sonst die ganzen Links sind:
Fatal error: Cannot redeclare reorder_cat() in /usr/export/www/vhosts/funnetwork/hosting/viper2/admin/admin_links_cat.php on line 45
Das ist der passende Abschnitt aus der Datei:

Code: Alles auswählen

// --------------------------
// This function will sort the order of all categories
//
function reorder_cat()
{
	global $db;

	$sql = "SELECT cat_id, cat_order
			FROM ". LINK_CATEGORIES_TABLE ."
			WHERE cat_id <> 0
			ORDER BY cat_order ASC";
	if( !$result = $db->sql_query($sql) )
	{
		message_die(GENERAL_ERROR, 'Could not get list of Categories', '', __LINE__, __FILE__, $sql);
	}

	$i = 10;

	while( $row = $db->sql_fetchrow($result) )
	{
		$sql = "UPDATE ". LINK_CATEGORIES_TABLE ."
				SET cat_order = $i
				WHERE cat_id = ". $row['cat_id'];
		if( !$db->sql_query($sql) )
		{
			message_die(GENERAL_ERROR, 'Could not update order fields', '', __LINE__, __FILE__, $sql);
		}
		$i += 10;
	}
}
// END
// --------------------------
Ich hab leider keine Ahnung was da los ist. Vielleicht kann mir ja jemand helfen?

MfG
...:::Stulle:::...