WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I'm trying to get the value of a $_GET variable on the homepage of my site. For some reason I can't access any $_GET variables on the homepage, but I can access them just fine on other pages. Does anyone know why this might be?

share|improve this question
can you give us some sample code? $_GET should be accessible in all pages. what do you get when u do echo $_GET ? – rexposadas Dec 9 '11 at 22:31

Most probably the reason is that WordPress uses the default query on the homepage, which maybe the reason why you are getting an empty array for $_GET.

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.