46 posts
  • 5 Years of Membership
  • Author Level 3
  • Exclusive Author
Codename
says

Hey guys, I just uploaded my first wordpress theme and I have to say that TF is great :-) Since I’‘m not a WP expert, I needed some advice.

The problem is that when permalinks are enabled in the theme, the pagination breaks. I’m guessing that this is since the get variables aren’t available to the page once the url has been rewritten. So is there any way that I could retrieve the GET array from the rewritte url?

Thanks.

1787 posts
  • Winner
  • Author Level 4
  • Exclusive Author
  • 5 Years of Membership
+2 more
VisualSharing
says

I believe some code snippet would come in handy here. :)

Good luck with your theme!

193 posts
  • 4 Years of Membership
  • Author Level 2
  • Exclusive Author
Kontent
says

Hi, it doesn’t matter if the url is rewritten, you get it the normal way because the rewritten url acts as the original url.

743 posts
  • Elite Author
  • Weekly Top Seller
  • Featured Item
  • Most Wanted Winner
+5 more
Orbital_Themes
says
Hi, it doesn’t matter if the url is rewritten, you get it the normal way because the rewritten url acts as the original url.

That’s right. Just make sure you use the WP functions for all pagination links etc. Also set the 'paged' query attribute to get_query_var($paged) and reset query after the loop.

46 posts
  • 5 Years of Membership
  • Author Level 3
  • Exclusive Author
Codename
says

Hi Pogoking, I reset the query after the loop, but I don’t understand what you meant by “Also set the ‘paged’ query attribute to get_query_var($paged)” ?? Btw, I have 2 queries on thepage, one for a featured post and then the next query which displays 4 posts with offset = 1. And I calculate the offset for each post based on the page number from the “paged” value of the GET array and offset the query by that number.

Also, since the permalinks do not affect the GET array, shouldn’t I be able to print the array? But when I do so I get an empty variable…

by
by
by
by
by
by