Take the 2-minute tour ×
WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. It's 100% free, no registration required.

I'm using permalinks and I have a page with a slug like this:

http://www.mysite.com/jobs/

The page uses a specific template for itself.

On another page I have a form that I submit as POST to http://www.mysite.com/jobs/. However, when the form is submitted, it takes me to the proper /jobs/ page, but the template is not correct. Even though the url is correct. I appears to use maybe the index or default template for some reason. If I click in the address bar of the browser and press enter to re-visit the same page, then the proper template appears.

It's like submitting a POST form to this page makes it use the wrong template even though the permalink slug is exactly the same as when I visit it normally.

Any clues?

share|improve this question

1 Answer 1

Make sure your form elements aren't using any names that WordPress uses, like name or s, this will cause the behavior you describe because it changes the type of query. Give them all names you are certain are unique.

share|improve this answer
    
One of my form inputs was named "s". That was the problem. I guess Wordpress was trying to treat it as a normal site search. Thanks a bunch! –  Jakobud Sep 8 '11 at 15:39
    
I had a input named name... now I'm super-happy I found your answer! –  estrar Jul 30 at 20:45

Your Answer

 
discard

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.