reworked loadLanguageFile function for better usage with ajax scripts