We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 33703 ☆ A M B ☆
    • 69 Posts
    Hello, i didn't find in the docs how to use Lingua with MIGX TVs,
    here's an example :
                        <div class="texte">
                            [[!lingua.getValue? &field=`weekender_texte` &id=`7`]]
                        </div>
                        <div class="event">
                            [[getImageList?
                            &tvname=`weekender_events`
                            &docid=`7`
                            &tpl=`chk_weekender_event`]]
                        </div>
    


    All the standard TVs of the document (like weekender_texte) are translating fine.

    But i've got a MIGX one : weekender_colonne, with 3 fields (titre, date, texte)
    this tv is also "Lingua enabled" and both english/french are filled in the Manager.

    here's the chunk for this TV : chk_weekender_event :
    <div class="weekender_event">
        <h3>[[+titre]]</h3>
        <div class="date">[[+date:nl2br]]</div>
        <div class="texte">[[+texte]]</div>
    </div>
    

    if i don't use lingua, it's OK like this,
    but i'm unable to find the correct syntax to display these fields in english/french.

    i tried a few things like this in the chunk,
    [[!lingua.getValue? &field=`weekender_event.texte ` &id=`7`]]

    or in the snippet call :
    [[getImageList?
        &tvname=`[[!lingua.getField? &field=`weekender_event` &id=`7`]]`
        &docid=`7`
        &tpl=`chk_weekender_event`]]
    


    but nothing return…


    Can anyone give me the correct syntax needed to display MIGX TV with Lingua ?

    Merci d'avance !
      made with MODx => France Douglas || Vintage Weekender
      • 4172
      • 5,888 Posts
      try this:

          [[getImageList?
          &tvname=`weekender_events` 
          &value=`[[lingua.getField? &field=`weekender_events` &id=`7`]]`
          &tpl=`chk_weekender_event`]]


      you could also try to have everything in one MIGX-TV without setting it up as translatable and have fields like:

      texte_fr, texte_en, texte_de

      Then have in the tpl-chunk:

      [[+texte_[[++cultureKey]]]]


        -------------------------------

        you can buy me a beer, if you like MIGX

        http://webcmsolutions.de/migx.html

        Thanks!