Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Adriano Fabri 469 posts 1633 karma points
    Apr 19, 2016 @ 14:25
    Adriano Fabri
    0

    Custom language file for Package not loaded

    Hello, I want to create my custom language file for my package.

    When I create my custom area and key into /Umbraco/Config/Lang/en.xml file, the localization function properly.

    Now I created my custom Lang folder with my custom en.xml file

    <?xml version="1.0" encoding="utf-8" standalone="yes"?>
    <language alias="en" intName="English (UK)" localName="English (UK)" lcid="" culture="en-GB">
        <creator>
            <name>ADRIANO</name>
            <link></link>
        </creator>
        <area alias="sections">
            <key alias="ADRIANO">ADRIANO</key>
        </area>
        <area alias="ADRIANO">
            <key alias="Button">Button</key>
        </area>
    </language>
    

    I put my custom Lang folder into my Package folder.

    App_Plugin
        |=>ADRIANO
            |=>backoffice
                |=>test
    

    I tried to put the "Lang" folder in

    App_Plugin/ADRIANO

    and also in

    App_Plugin/ADRIANO/backoffice/test/

    but the text of my button is always

    [ADRIANO_Button]

    What's wrong?

  • Jan Skovgaard 11280 posts 23678 karma points MVP 11x admin c-trib
    Apr 20, 2016 @ 05:32
    Jan Skovgaard
    0

    Hi Adriana

    What exact version of Umbraco 7 are you using? This option was not introduced untill the release of 7.3.

    You can see the documentation about how to use it here if you have not done so already https://our.umbraco.org/documentation/Extending/Language-Files/Language-Files-For-Packages/

    Hope this helps.

    /Jan

  • Adriano Fabri 469 posts 1633 karma points
    Apr 20, 2016 @ 08:22
    Adriano Fabri
    0

    Hi Jan, first of all my name is Adriano :-)

    Thank you for reply...I'm using Umbraco version 7.4.1 assembly: 1.0.5891.23238

    I have read that link and as I wrote in my post I tried to put the Lang folder in

    App_Plugin/ADRIANO

    but the text of my button is always

    [ADRIANO_Button]

    I don't understand if I must declare it or include a directive to tell Umbraco that there is a custom language files or Umbraco should find automatically my custom language file and use it

    (Sorry my not perfect english) :-)

  • Micha Somers 134 posts 597 karma points
    Apr 20, 2016 @ 09:14
    Micha Somers
    101

    Hi Adriano,

    Rename your en.xml file to en-GB.xml, put it in the App_Plugin/ADRIANO/lang folder ... and see the magic happen!

  • Adriano Fabri 469 posts 1633 karma points
    Apr 20, 2016 @ 09:55
    Adriano Fabri
    1

    perfect...it works like a charm!!!

    Thank you!

  • Jan Skovgaard 11280 posts 23678 karma points MVP 11x admin c-trib
    Apr 20, 2016 @ 11:44
    Jan Skovgaard
    1

    Hi Adriano

    Sorry about the spelling mistake - It went a bit fast.

    Happy to see that M. Somers came up with the correct solution to your issue. I should have thought of that myself as well.

    When working with property editors and language versioning it's also important to clear the browser cache from time to time or maybe even Umbraco's backoffice cache in order to see the changes take effect when editing the language files or adding new items to them.

    Happy developing :)

    /Jan

  • Caglar Tasci 19 posts 125 karma points
    Feb 13, 2017 @ 21:30
    Caglar Tasci
    0

    I had the same issue. Had to touch the web.config file to clear the backoffice's cache. only enabling the debuggers "Disable cache (while DevTools is open)" was not enough.

  • John Sharp 4 posts 74 karma points
    Apr 23, 2018 @ 17:41
    John Sharp
    0

    Hi Adriano,

    I'm stuck with the same problem. I think mine is because I don't know how to create the package correctly. Do you have any advice?

    Cheers,

    John

  • George Phillipson 108 posts 287 karma points
    Jun 19, 2021 @ 23:29
    George Phillipson
    0

    I know this is an old post, I had the same problem and in the end, the only way I could get it to work was to go to: /umbraco/config/Lang/

    find en-us and then search for dashboardTabs and then manually add my alias.

    Once done it worked OK

Please Sign in or register to post replies

Write your reply to:

Draft