50 if ( file_exists( LEPTON_PATH.
'/languages/'.$file ) && preg_match(
'#^([A-Z]{2}[_custom]{0,1}.php)#', basename( $file ) ) )
52 $language_license =
null;
53 $language_code =
null;
54 $language_version =
null;
55 $language_delete =
true;
56 $language_guid =
null;
57 $language_name =
null;
58 $language_author =
null;
59 $language_platform =
null;
61 require LEPTON_PATH.
'/languages/'.$file;
63 if ( ( $language_license == NULL )
64 || ( $language_code == NULL )
65 || ( $language_version == NULL )
66 || ( $language_guid == NULL )
69 echo(
LEPTON_tools::display($MESSAGE[
"LANG_MISSING_PARTS_NOTICE" ]. $language_name,
'pre',
'ui red message'));
73 $sqlwhere =
'`type` = \'language\' AND `directory` = \'' . $language_directory .
'\'';
74 $sql =
'SELECT COUNT(*) FROM `' . TABLE_PREFIX .
'addons` WHERE ' . $sqlwhere;
86 'directory' => $language_directory,
87 'name' => $language_name,
89 'version' => $language_version,
90 'platform' => $language_platform,
91 'author' => addslashes( $language_author ),
92 'license' => addslashes( $language_license ),
93 'to_delete' => intval( $language_delete ),
94 'guid' => $language_guid,
100 TABLE_PREFIX .
"addons",