Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Product pages not working in second language #155

Closed
herrvigg opened this issue Jun 22, 2018 · 16 comments
Closed

Product pages not working in second language #155

herrvigg opened this issue Jun 22, 2018 · 16 comments
Labels
bug Something isn't working, reproducible legacy issue Legacy issue imported from original repo module: WC Integration with Woo Commerce need info The submitter must provide more info

Comments

@herrvigg
Copy link
Collaborator

Issue by DaphneNL
Friday May 08, 2015 at 13:04 GMT
Originally opened as qTranslate-Team/qtranslate-x#155


First of all I would like to thank you for this amazing plugin. Works like a charm (well, accept in this case of course, ;) ). My problem: The main language of my website is Dutch, and everything works fine in Dutch. My second language is English, and almost everything works except for one thing (I think, I haven't checked the rest yet): When you pick a category on my website, http://dapsseeds.pridesranch.nl , the first product page shows up nicely, but if you want to see the second page (like in the category "cherry/cocktail" with lots of varieties) you will be directed straight to the home page. I've tried playing around with slugs, de- and re-activating plugins, changing permalinks, but I just can't seem to find the problem. I don't have much programming or scripting experience, do I hope someone can explain to me in a simple way what is wrong. Thanks!

Note from John Clause: Most likely the following problems are related:
https://wordpress.org/support/topic/pagination-does-not-work-if-query-mode-used
https://wordpress.org/support/topic/navigation-problem-20

@herrvigg herrvigg added bug Something isn't working, reproducible legacy issue Legacy issue imported from original repo labels Jun 22, 2018
@herrvigg
Copy link
Collaborator Author

Comment by DaphneNL
Saturday May 09, 2015 at 17:18 GMT


I just checked, with the old qtranslate plugin this problem doesn't occur, only with the qtranlate x plugin. But the qtranslate plugin messes up my layout.

@herrvigg
Copy link
Collaborator Author

Comment by johnclause
Monday May 11, 2015 at 02:50 GMT


@DaphneNL : there has been some changes in the latest q-X available from GitHub. We would greatly appreciate if you could test your original problem again and see if it is gone?

The test version can be downloaded from GitHub page with button "Download ZIP", or click here for the sake of convenience.

@herrvigg
Copy link
Collaborator Author

Comment by DaphneNL
Monday May 11, 2015 at 20:13 GMT


Yes! It's working! Thank you so much!

@herrvigg
Copy link
Collaborator Author

Comment by johnclause
Tuesday May 12, 2015 at 04:58 GMT


Thank you for testing. I am closing it now. We may still write to closed issue and we can re-open it if needed.

@herrvigg
Copy link
Collaborator Author

Comment by klumme
Monday Jun 01, 2015 at 08:21 GMT


I seem to be running into the same issue on search result pages, even with the latest version from GitHub. This happens only for secondary languages: the first page has the query ?s=&lang=en but the link to previous posts only points to ?paged=2&lang=en.

@herrvigg
Copy link
Collaborator Author

Comment by johnclause
Tuesday Jun 02, 2015 at 00:10 GMT


I went to your site http://dapsseeds.pridesranch.nl and it seems working correctly. I guess I need steps to reproduce.

@herrvigg
Copy link
Collaborator Author

Comment by klumme
Tuesday Jun 02, 2015 at 08:14 GMT


I'm not the original poster so that is not my site, but it can be reproduced there, at least on my end:

Go to the site, make sure the language is English.
Add a search query to the end of the URL, like &s=tomato.
Scroll to bottom, click "Older posts".
This takes you to the front page.

On that site, using the search box doesn't cause the same problem, which I'm guessing is because the search is done with a post type. On a site of mine, using the search widget results in the query above, the results of which have broken navigation.

@herrvigg
Copy link
Collaborator Author

Comment by johnclause
Tuesday Jun 02, 2015 at 15:44 GMT


Indeed. I was using the search box, then url is ?s=tomato&post_type=product&lang=en and then a different navigation appears for some reason, which works fine.

Could you think of a way to reproduce it under one of the standard themes? I was trying under StoreFront and it works correctly.

@herrvigg
Copy link
Collaborator Author

Comment by johnclause
Tuesday Jun 02, 2015 at 16:29 GMT


BTW, can you try different "URL Modification Mode", like "Pre-Path Mode", which most people use? Does the problem happen for you there too?

@herrvigg
Copy link
Collaborator Author

Comment by johnclause
Tuesday Jun 02, 2015 at 17:01 GMT


Can you try the latest from GitHub? I cancelled filter qtranxf_convertBlogInfoURL for URL Modification Query Mode. Does it solve your problem?

@herrvigg
Copy link
Collaborator Author

Comment by klumme
Wednesday Jun 03, 2015 at 10:44 GMT


Latest from GitHub did not solve the problem, but changing to pre-path mode works. Pre-path mode is nicer, of course, and I can probably manage to change my problematic site to that. Still, I suppose query mode should work...

Couldn't reproduce on the standard themes, but they use the_posts_pagination(), not the_posts_navigation() in their search templates (Twenty Thirteen seems to have some custom thing). My theme is a custom one based on _s. It is not impossible that I'm the one doing something stupid in my theme, I'll have to take a look.

Thanks for looking into this!

@herrvigg
Copy link
Collaborator Author

Comment by klumme
Wednesday Jun 03, 2015 at 13:18 GMT


It seems the problem is not related to the bloginfo_url hook but rather the home_url hook. Removing the qtranxf_home_url filter makes navigation work (don't know what else this might break, though).

@herrvigg
Copy link
Collaborator Author

Comment by johnclause
Wednesday Jun 03, 2015 at 15:54 GMT


Yes, they both add /?lang=xx to the url and WP assumes the url without a query string. Yes, changing home_url may break many sites, but maybe if we do it for Query Mode only, it would be fine. Did you try to use Pre-Path mode? Does the problem happen then?

@herrvigg
Copy link
Collaborator Author

Comment by johnclause
Wednesday Jun 03, 2015 at 16:15 GMT


I've disabled filter 'home_url' in Query Mode. Since majority do not use Query mode, they will be unaffected, and even those who do, may still be fine, since things a bit different in Query Mode. Hopefully not many will have a trouble, and if somebody does we will fix them by other meaning.

I am still curious if your problem is gone in none query mode?

@herrvigg
Copy link
Collaborator Author

Comment by klumme
Thursday Jun 04, 2015 at 07:26 GMT


Ok, thanks! Yep, as I wrote above, pre-path mode worked fine for me.

@herrvigg
Copy link
Collaborator Author

Comment by johnclause
Thursday Jun 04, 2015 at 16:00 GMT


Does the latest from GitHub work for you even in Query Mode? I am doing it blindly, since I could never reproduce the problem under my themes. Can we close this issue?

@herrvigg herrvigg added module: WC Integration with Woo Commerce need info The submitter must provide more info labels Apr 24, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working, reproducible legacy issue Legacy issue imported from original repo module: WC Integration with Woo Commerce need info The submitter must provide more info
Projects
None yet
Development

No branches or pull requests

1 participant