mercredi 29 juin 2016

URL repeats itself, leading to a 404 error


My page will redirect the user to another page which will handle all the updating information. I got the redirect in itself working, problem is, the URL isnt what i expect it to be, leading to a 404 error. Let me try to exemplify.

The user clicks a button, redirecting him to "test.com/main/update.php". But my file is in "test.com/test/RazorFinger/update_test.php". so it ends up being something like this:

<FORM name=form id="form" action="test.com/main/update.php?area=<?=$GetArea?>&etc..." method="POST" target='_blank'>

So my main URL is this:

http://test.com/teste/RazorFinger/update_test.php?area=TestArea&proj_id=1234&task_uid=1

And the redirected url is basically:

http://test.com/teste/RazorFinger/test.com/main/update.php?area=TestArea&etc..etc..etc..

The question might be a bit complicated because i'm using fake URLs as example, but basically, i can't get out of "test.com/test" and into "test.com/main", and that leads me to a 404 error. So what's wrong?


Aucun commentaire:

Enregistrer un commentaire