PCkuijper Posted October 21, 2014 Share Posted October 21, 2014 I'm working on implementing apeisa's shop module in our new multilanguage website. But when i switch to the english version of the site it fails to find the order. The selector used: template=sc-order, sc_session={$sid}, status=unpublished, limit=1, sort=-created returns the correct page on the default language, but returns nothing on a secondary language. I've checked the session and that remains exactly the same. I've found that when I check the active box on the 2nd language url on it works again. But haven't found a way to automatically do this when creating the orders. Link to comment Share on other sites More sharing options...
SiNNuT Posted October 21, 2014 Share Posted October 21, 2014 If a page is not active for your secondary language there is nothing to find/get in that language. If you create orders via the API you can set a language active via this: https://processwire.com/talk/topic/4383-how-to-set-language-active-via-api/ Pages created via the PW admin should already activate all languages by default. 1 Link to comment Share on other sites More sharing options...
PCkuijper Posted October 21, 2014 Author Share Posted October 21, 2014 Hey SiNNuT, Thank you for your help. My search skills have failed me. The solution Soma offered (slightly modified) worked in my situation and now my customers can shop in happyness. 1 Link to comment Share on other sites More sharing options...
SiNNuT Posted October 21, 2014 Share Posted October 21, 2014 Glad you got it sorted. If you've searched via the native forum search i'm gonna give you a tip: Always use Google to search the forum. Native search is downright useless most of the times and pretty crappy at best. "site:processwire.com/talk set language active api" in Google would have given some results Link to comment Share on other sites More sharing options...
PCkuijper Posted October 22, 2014 Author Share Posted October 22, 2014 I always use google to find my answers, although without the site:processwire.com/talk (PW forums tend to be the top 10 results anyway). But for some reason I couldn't find it anywhere. Guess my searched weren't formatted as they should've (overcomplicated things) Thanks once more 1 Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now