Home Forums ePix Support Search issue for multilingual website

Viewing 9 posts - 1 through 9 (of 9 total)
  • Author
    Posts
  • #56678

    Simone pasqualini
    Participant

    Hello,

    I’m using mqTranslate to translate my woocommerce because I hate the WPML transation method.
    Just a problem with the WP Search

    So people found the solution changing the searchform.php file

    Solution can be found here https://wordpress.org/support/topic/plugin-qtranslate-problem-with-the-search-results-on-a-bilingual-website?replies=3 with the code:

    <form id=”search” method=”get” action=”index.php”>

    <div>
    <input type=”text” value=”<?php the_search_query(); ?>” name=”s” id=”s” />
    <input type=”submit” id=”searchsubmit” value=”<?php _e(‘[:fr]Recherche[:en]Search’,’TheSource’); ?>” />
    </div>
    </form>

    but it’s not working.

    Can you help, please?

    Thanks
    S.

    #56679

    Simone pasqualini
    Participant

    for example this link -> http://laboratorio35.com/search/boots?lang=ja or http://laboratorio35.com/search/boots?lang=fr or http://laboratorio35.com/search/boots?lang=en found everytime all products for each language.

    I do not understand the reason why the Search function does not generates links like this -> http://laboratorio35.com/search/boots?lang=ja but use this http://laboratorio35.com/ja?s=boots where nothing is find.

    Can you help to change the slug for the Search so I can shown links like this http://laboratorio35.com/search/boots?lang=ja where I’m sure that products are shown?

    Thanks
    Simone

    #56684

    Tom ( Support)
    Keymaster

    Hi Simone,

    As this is not really a theme issue, there is limited support I can supply. Have you had a look at this post though? It states to add the following for code to the very bottom of the themes functions.php file which is under epix/functions.php.

    Might be worth a shot?

    remove_filter('get_search_form', 'qtrans_fixSearchForm',0);
    add_filter('get_search_form',	'qtrans_fixSearchForm_yop', 10, 1);
    function qtrans_fixSearchForm_yop($form) {
    //$form = preg_replace('#action="[^"]*"#','action="'.trailingslashit(qtrans_convertURL(get_home_url())).'"',$form);
    
    //qtranslate Slug compatibilidad, no duplicar en url idioma /es/es/ al buscar (search)
       $form = preg_replace('#action="[^"]*"#','action="'.trailingslashit(get_home_url()).'"',$form);
    
    	return $form;
    }
    

    Hope this helps.
    Tom

    #56686

    Simone pasqualini
    Participant

    ok now I try however do you think that you could solve some issues that I have with a payment?

    Thanks
    Simone

    #56690

    Simone pasqualini
    Participant

    the code is not working.

    #56723
    Andy
    Andy
    Keymaster

    Hi Simone,

    Can you provide your WP login details please so we can investigate a little further, thank you.

    #56727

    Simone pasqualini
    Participant
    This reply has been marked as private.
    #56763
    Andy
    Andy
    Keymaster

    Hi Simone,

    I don’t want to change themes for you, but can you try switching to the default Twenty Fourteen theme and see if you experience the same issue please. If you do, I recommend posting onto the plugin support forums to see what they recommend to resolve the issue as it seems to be directly related to the plugin and not the themes.

    #56765

    Simone pasqualini
    Participant

    Regards

Viewing 9 posts - 1 through 9 (of 9 total)

You must be logged in to reply to this topic.

© 2019 Acoda