cotonti.com : Bug in functions.php? https://www.cotonti.com Laatste forum onderwerpen Cotonti en Thu, 01 Jan 2026 03:16:35 -0000 esclkm fix

]]>
Di, 06 Sep 2011 21:26:43 -0000
Mr G. Hi, i'm not so good in php. but i thik i found a bug in function cot_langfile

there is in lines 2655-2658

elseif ($type == 'core')
	{
		return $cfg['lang_dir']."/$default/$name.$default.lang.php";
	}

so the language change doesn't work, i think there should be something like this

elseif ($type == 'core')
	{
		if (@file_exists($cfg['lang_dir']."/$lang/$name.$lang.lang.php"))
		{
			return $cfg['lang_dir']."/$lang/$name.$lang.lang.php";
		}
		else
		{
			return $cfg['lang_dir']."/$default/$name.$default.lang.php";
		}
	}

but i might be wrong...., as i said i'm not so good in php

]]>
Di, 06 Sep 2011 08:53:59 -0000