Welcome to the Treehouse Community
Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.
Looking to learn something new?
Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.
Start your free trialahmed saleh
2,754 Pointsi have another idea , but i'm not sure if it's correct or even work ? title(Redirecting after form submission)
i'm not sure if i get it very well but i guess that is what happend 1- all the information store in $_post variable . 2- the $_post variable still have these submit information ( until what , i don't know actually..) .
so my question why we don't set $_post variable to null and then nothing is gonna submit again , also why the browser doesn't empty this variable by its self ? after using it i mean . thank you
1 Answer
shawn stokes
5,651 Points$_post is general set by a form when you hit submit there would be no reason to set it to null that i can think of. when you redirect some one after a form submission the $_post data for the most part will be emptied. unless you are storing it some other way.