+ 1

Include file php cons.

What to do if I am including a file that has a form that will return to itself when I submit that form and have the stuff to do when it submits the form. All I am getting the problem is that when I submit that form it takes me to the file where I included that file. I have not words to explain...

8th Mar 2019, 9:17 PM
Praveen Soni
Praveen Soni - avatar
4 ответов
+ 1
Dyf Dyf action refers to same page. <Form action="#" >
21st Mar 2019, 3:44 PM
Praveen Soni
Praveen Soni - avatar
+ 1
If I got it right you got a file A.php Inside A.php you got a form which is include from B.php and all the treatment and stuff are done in B.php (the form page) ? If it is like so you shouldn't have <form action=#> but <form action='B.php'> cause # refer to the current webpage and B (the form) being include in A the current page is A.php and not the B.php page you were aiming for Hope I'm comprehensible enough and not too late Good luck with that and it was not caused by that, do not hesitate to share your code
23rd Mar 2019, 12:32 PM
Dyf Dyf
Dyf Dyf - avatar
+ 1
Dyf Dyf thank you 😄
24th Mar 2019, 5:27 PM
Praveen Soni
Praveen Soni - avatar
0
Verify the action you asked your form to do <Form type='post' action='x.php' > Is it the good page you call ? Is there any include or require on your form page ?
18th Mar 2019, 7:16 PM
Dyf Dyf
Dyf Dyf - avatar