I Love PHPMaker

... because it gets even more powerful and flexible!!

  • About
  • Terms and Conditions
  • Membership Options
  • Sitemap
  • Downloads
    • PHPMaker Extensions Download
    • PHPMaker Projects Download
    • PHP Report Maker Extensions Download
I Love PHPMaker » Tips and Trick » How to Separate and Maintain the XML Language Files in PHPMaker
How to Enable/Disable TextBox Based On CheckBox Click in Web Applications that Generated by PHPMaker 10.0.5
How to Implement Regional Settings in Web Applications that Generated by PHPMaker

April 12, 2014

How to Separate and Maintain the XML Language Files in PHPMaker

For those of you who have been implementing the Breadcrumb Links using Masino Extensions, then you have to insert the additional Breadcrumb phrases into the XML Language files. This files are located under the languages sub-folder of PHPMaker installation. Most of the time, each of your PHPMaker project uses the different Breadcrumb phrases. Thus, if you always use the same XML Language file for all of your projects, then you need to backup each XML Language file in the different folder. The reason for this, since the XML Language file name is the same for all projects, and you don't want to replace the XML language that belongs to the old project with the current project. Each time you want to use the right XML Language file, then you have to copy them into the languages sub-folder. Believe me, even this issue looks not too serious, but this condition is not good and also annoying for you!

Today I just found out the solution to solve this issue, and honestly, I have been waiting to try to implement it for a long time ago. And Thank God, today I successfully implemented it. All we have to do is to separate and maintain the XML Language files in the different file name and to distinguish the name attribute that belongs to ew-language in the XML Language files. This change will now cause you can simply put all the XML Language files in the same folder. No worry about the clashing of XML Language files anymore. In other words, you don't need to separate the XML Language files to the different folder anymore. You don't need also to copy the right files to languages sub-folder before working in your PHPMaker project. This will save a lot of your time and also will enable you to select the right XML Language files from Tools -> Languages of PHPMaker.

Now I will show you the example of usage how to implement it step-by-step, to make it easier for you to understand the solution above.

  1. Let's say when we have just installed PHPMaker for the very first time, we already have english.xml file, right? We can see in the second line from the top of that XML file contains the following code:

    <ew-language date="2013/08/02" version="10.0.1" id="en" name="English" desc="English" author="e.World Technology Ltd.">
    
  2. Now let's say also you want to translate it into your native language other than English. For example, I want to create the translation of that file into Indonesian, then I will save that file above as indonesian.xml and then change the code above become:

    <ew-language date="2014/04/12" version="10.0.5" id="id" name="Indonesian" desc="Indonesian" author="Masino Sinaga">
    
  3. Until this step, let's make sure those both languages have been listed and displayed correctly from PHPMaker. Simply click on Tools -> Languages from PHPMaker application, then you should see now there are two languages available in there as follows:

    • English
    • Indonesian
  4. Now let's make a deal by leaving the original XML Language files above as it is. They will be useful whenever we want to use the original XML Language files before adding the additional phrases, okay?
  5. The next step, let's say now, you want to create another XML Language files for your certain new PHPMaker project named demo10. To do this, we will create another two XML Language files based on those two original XML Language files above.
  6. In order to distinguish the existing XML English Language, we will open the english.xml file, save it as english_demo10.xml and don't forget to change the code in the root node become:

    <ew-language date="2014/04/12" version="10.0.5" id="en" name="English Demo 10" desc="English" author="Masino Sinaga">
    
  7. The same way also to distinguish the existing XML Indonesian Language, we will open the indonesian.xml file, save it as indonesian_demo10.xml and don't forget to change the code in the root node become:

    <ew-language date="2014/04/12" version="10.0.5" id="id" name="Indonesian Demo 10" desc="Indonesian" author="Masino Sinaga">
    
  8. Until this step, now let's check them from PHPMaker. Click on Tools -> Languages menu, then you should see now there are four XML Language files available:

    • English
    • English Demo 10
    • Indonesian
    • Indonesian Demo 10
  9. As you can see now, you may select the related XML Language files only for the current PHPMaker project that you are working on it. For example, now you are working on demo10 project, then you should include the XML Language files by selecting English Demo 10 and Indonesian Demo 10 from Tools -> Languages.

That's it! Now you may try this solution for all of your PHPMaker projects. So, have a nice try, everyone! 🙂

Article by Masino Sinaga / Tips and Trick / english.xml, indonesian.xml, Language, language file, language selector, languages selection, multi language, multilanguage, PHPMaker 10.0.5, selected language, xml language file 2 Comments

How to Enable/Disable TextBox Based On CheckBox Click in Web Applications that Generated by PHPMaker 10.0.5
How to Implement Regional Settings in Web Applications that Generated by PHPMaker

Comments

  1. Jian Yi Yang says

    July 31, 2014 at 2:04 pm

    good, I just thinking about How I separate Language Definition by each Multi-Language-Project…
    So in this case, How do I access the “English Demo 10” Language object ??

    Still $Language ??

    Log in to Reply
    • Masino Sinaga says

      July 31, 2014 at 6:49 pm

      Exactly. There is no change either for language global variable or the method to get/set/display the phrases. You can still use $Language or Language() global function.

      You can follow this post to see the project how to include the demo language file.

      Log in to Reply

Leave a Reply Cancel reply

You must be logged in to post a comment.

This site uses Akismet to reduce spam. Learn how your comment data is processed.

Recent Posts

  • A New PHPMaker 2024 Project File Is Released
  • PHPMaker 2024 Demo Project File Is Released
  • Masino Extensions for PHPMaker 2024 Is Released!
  • PHPMakerProjects.com, For Those Who Need PHPMaker Project Sample
  • A New PHPMaker 2023 Project File Is Released
  • PHPMaker 2023 Demo Project File Is Released
  • Masino Extensions for PHPMaker 2023 Is Released!
  • A New PHPMaker 2022 Project File Is Released
  • PHPMaker 2022 Demo Project File Is Released
  • Masino Extensions for PHPMaker 2022 Is Released!

Search

Recent Comments

  • Masino Extensions untuk PHPMaker 2024 Sudah Dirilis, Silahkan Download! – Masino Sinaga on Membership Options
  • Masino Sinaga on Masino Extensions for PHPMaker 2022 (All-In-One)
  • Filipe Vercesi on Masino Extensions for PHPMaker 2022 (All-In-One)
  • Mandwa on Masino Extensions for PHPMaker 2023 Is Released!
  • Masino Sinaga on Masino Extensions for PHPMaker 2023 Is Released!

Demo Website

  • Demo of I Love PHPMaker 2024 (MasinoExtensions).
  • Stock Inventory Management for PHPMaker 2024.
  • Stock Inventory Management for PHPMaker 2023.
  • Stock Inventory Management for PHPMaker 2022.
  • Stock Inventory Management for PHPMaker 2021.

Another Demo

The following template are not available in this site (must be purchased separately)

  • PHPMaker v2018 Horizontal Vertical Template.
  • PHPMaker v2017 Horizontal Vertical Template.

Demo Explanation

Stock Inventory Management is the good project for your reference, since it uses the real example in the real world. Many useful features you can use from this project, such as how to add the Thousand and Decimal separator character, and also how to calculate multiple row in Grid-Add when End-Users are entering data into the Grid-Add mode.

Categories

  • Customize Template (103)
  • General (4)
  • PHP Report Maker (17)
  • PHP Report Maker Extensions (2)
  • PHPMaker Extensions (83)
  • PHPMaker Projects (5)
  • Tips and Trick (72)

Articles based on version

  • PHPMaker 2024
  • PHPMaker 2023
  • PHPMaker 2022
  • PHPMaker 2021
  • PHPMaker 2020
  • PHPMaker 2019
  • PHPMaker 2018
  • PHPMaker 2017.0.7
  • PHPMaker 12.0.7
  • PHPMaker 11.0.6
  • PHPMaker 10.0.5
  • PHPMaker 9.2.0
  • PHPMaker 8.0.3
  • PHP Report Maker 12

(c) I Love PHPMaker 2010 - 2023 by Masino Sinaga | WordPress | Log in | Back to top