-
AuthorPosts
-
August 6, 2014 at 10:29 pm #300853
I can get ajax results in my main language http://fiberreed.de/ but nothing with my second language http://fiberreed.com/
August 7, 2014 at 3:53 am #300932Hey maratino!
Thank you for using Enfold.
I was able to do a search on the english version of the site. I type in “sax” on the search field and the first result is “Fiberreed HEMP Soprano Saxophone”. I tried it again on the deutsche version using the same search characters, the first result is “Fiberreed HEMP Sopransaxophon”.
Best regards,
IsmaelAugust 7, 2014 at 8:38 am #300973This seems to happen in Chrome only and now i see an error:
XMLHttpRequest cannot load https://fiberreed.de/wp-admin/admin-ajax.php?lang=en. No ‘Access-Control-Allow-Origin’ header is present on the requested resource. Origin ‘http://fiberreed.com’ is therefore not allowed access.August 8, 2014 at 6:12 pm #301762Hi!
Yes, unfortunately ajax requests are not allowed across different domains (i.e. from http://fiberreed.de/ to http://fiberreed.com/ or vice versa). Afaik you can solve this with CORS: http://www.d-mueller.de/blog/cross-domain-ajax-guide/ but implementing such a solution is beyond the scope of our support forum. You can try to contact the WPML support staff – maybe they can provide a solution. Otherwise I recommend to deactivate the ajax search feature on the website with following code (insert it into the functions.php file):
add_filter('avf_frontend_search_form_param', 'avia_deactivate_ajax_search',10,1); function avia_deactivate_ajax_search($params) { $params['ajax_disable'] = true; return $params; }You could also change the url of the English website from http://fiberreed.com/ to http://fiberreed.de/en/ which would also solve the problem because the domain ( http://fiberreed.de/ ) is the same.
Best regards,
Peter -
AuthorPosts
- You must be logged in to reply to this topic.
