diff --git a/e107-Coding-Standard.md b/e107-Coding-Standard.md index bb7459c..dec2429 100644 --- a/e107-Coding-Standard.md +++ b/e107-Coding-Standard.md @@ -292,6 +292,14 @@ To check whether a particular plugin is installed, use function e107::isInstalle ## Language Files and LANS +To load a language file from the current theme's directory: + + e107::lan('theme'); // loads e107_themes/CURRENT_THEME/languages/English.php (when English is selected) + +To load a language file from a plugin folder: + + e107::lan('gallery'); // loads e107_plugins/gallery/languagues/English.php (when English is selected) + Avoid duplicating terms, particularly in the admin area. If coding for admin, always search lan_admin.php and the lan_xxxx.php of the specific page you are working on for existing LANs which may match what you need translated. Avoid using HTML or Urls inside LAN definitions. **Good:**