function lget($id, $language, $fallbackLanguage) { //Retrieve a localizable string. $db = new FractureDB('futuqiur_ember'); $ld = getRowDF('strings', 'id', $id, 'language', $language); if (is_null($ld)) { $ld = getRowDF('strings', 'id', $id, 'language', $fallbackLanguage); } if (is_null($ld)) { $ld = getRow('strings', 'id', $id); } if (isset($ld[0])) { return null; } return retrieve($ld['data']); }
function ltest($language, $id) { //Test for presence of a localizable string. $db = new FractureDB('futuqiur_ember'); $res = getRowDF('strings', 'language', $language, 'data', $id); if (is_null($res)) { return null; } return $res['id']; }