+ Reply to Thread
Results 1 to 5 of 5

Thread: Multilanguage Description in Listings

  1. #1
    Junior Member
    Join Date
    Dec 2022
    Posts
    21

    Multilanguage Description in Listings

    Hello,

    i tryed to get a short description in listing and put the follwing code in listing.tpl


    {if $listing.additional_information != NULL}
    <div class="table-cell small clearfix">
    {$listing.additional_information|replace:'...':''| truncate:150:'..'}
    </div>

    With one language it works good, bit i have 2 languages activated

    Now i get a {|de|} in front of description.

    I am unfortunately not yet very familiar with the framework
    Please could you help how to fix this?
    Which Framework do you using for this?

  2. #2
    Junior Member
    Join Date
    Dec 2022
    Posts
    21
    Hello,
    if you cant answer my question, can you tell me which template are controlling the language output of additional information?

  3. #3
    Flynax developer Rudi's Avatar
    Join Date
    Dec 2014
    Location
    Planet Earth
    Posts
    3,138
    Hello,

    You need to use this variable to access formatted listing data:

    {$listing.fields.FIELD_KEY.value}

    your field is also should be added to the browse form of the related category

  4. #4
    Junior Member
    Join Date
    Dec 2022
    Posts
    21
    Hello,
    i tryed a cupple thingit but it is not working

    {$listing.fields.additional_information.value} - nor result
    {$listing.fields.additional_information.de} - nor result
    {$listing.listings.additional_information.de} - nor result
    {$listing.listings.additional_information.value} - nor result
    {$listing.additional_information.de.value} -> just the first sign of the sentence or the curly braces if it is on the first position

  5. #5
    Flynax developer Rudi's Avatar
    Join Date
    Dec 2014
    Location
    Planet Earth
    Posts
    3,138
    the correct case is {$listing.fields.additional_information.value}

    Make sure that this field exists on the browse form of your category

+ Reply to Thread