• Resolved cristiano771

    (@cristiano771)


    Hi David!
    I am opening this new topic for the problem using a translation plugin with mla_term_list.
    The code works fine with the page when the language is set to Italian:

    <form id="mla-text-form" action="." method="post" class="row">
    <table>
    <tbody>
    <tr>
    <td width="25%" valign="top">Categoria / Specie: </td>
    <td width="50%">
    [mla_term_list taxonomy=attachment_category mla_output=dropdown child_of="400" mla_control_name=main_category  depth=1 mla_item_parameter=current_main_category show_count=false use_filters=true]
    [mla_term_list taxonomy=attachment_category mla_output=dropdown include_tree=127 child_of="{+template:({+request:main_category+}|1)+}" mla_control_name=include_category mla_item_parameter=current_include_category show_count=true pad_counts=false hierarchical=true depth=1 use_filters=true]
    [mla_term_list taxonomy=attachment_category mla_output=dropdown mla_option_value="{+slug+}" exclude_tree=127 child_of="{+template:({+request:main_category+}|1)+}" mla_control_name=sub_category mla_item_parameter=current_sub_category show_count=true pad_counts=false hierarchical=true depth=0 use_filters=true][mla_term_list taxonomy=attachment_category mla_output=dropdown mla_option_value="{+slug+}" include_tree=127 child_of="{+template:({+request:include_category+}|1)+}" mla_control_name=third_category mla_item_parameter=current_third_category show_count=true pad_counts=false hierarchical=true depth=0 use_filters=true]</td>
    <td width="25%" valign="top">
    <input id="text-form-submit" name="text_form_submit" type="submit" value="SELECT">
    </td>
    </tr>
    </tbody></table>
    </form>
     <br>
    [mla_gallery]
    attachment_category="{+template:({+request:sub_category+}|{+request:third_category+}|no-term-selected)+}" tax_include_children=false
    posts_per_page=25 mla_output="paginate_links,prev_next" orderby=date order=DESC
    mla_link_href="{+new_url+}?mla_paginate_current={+new_page+}&main_category={+request:main_category+}&sub_category={+request:sub_category,url+}"
    [/mla_gallery]
     
    [mla_gallery columns=0 mla_style="responsive" size="thumbnail" attachment_category="{+template:({+request:sub_category+}|{+request:third_category+}|no-term-selected)+}" tax_include_children=false posts_per_page=25 orderby=date order=DESC mla_caption="{+title+} : {+description+}" mla_link_href="/modulo-richiesta-foto/?current_id={+attachment_ID+}" mla_nolink_text=" "]

    If you try to change the language (with the dropdown menu on the top right) and you select English or Spanish… when you press the button “Select” the page is refreshed and migrate to the home-page. You can see this using the link I added to this topic.
    I don’t know if it depends on the plugin or on the different url of translated pages…
    thanks for the infinite patience
    Cristiano

    The page I need help with: [log in to see the link]

Viewing 2 replies - 1 through 2 (of 2 total)
  • Plugin Author David Lingren

    (@dglingren)

    Thanks for starting a new topic. Thanks as well for setting up the separate test page; very helpful.

    I believe your problem is caused by TranslatePress, not MLA. TranslatePress is altering the “action” attribute in the < form > tag for the translated pages, and is not processing the original “dot” action, action=".", correctly. Here are the markup values I found for your test page:

    <form id="mla-text-form" action="/en/./" method="post" class="row" data-trp-original-action=".">
    
    <form id="mla-text-form" action="." method="post" class="row">
    
    <form id="mla-text-form" action="/es/./" method="post" class="row" data-trp-original-action=".">
    

    You can try replacing the action="." with action="/richiesta-foto-debug/". If that doesn’t solve the problem you can contact the TranslatePress support team to ask for a solution.

    I am marking this topic resolved because MLA does not seem to play any role in the issue. Please post an update if the above suggestion works or if you find another solution so others can benefit from your experience. Thanks for your understanding and for your continued interest in MLA.

    Thread Starter cristiano771

    (@cristiano771)

    Thank you, David! I just replaced the the parameter you have indicated and now all works fine!
    The working page (for every language!) is at this link.

    Have a nice weekend!
    Cristiano.

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘mla_term_list not working with Translate Press’ is closed to new replies.