Php uses the hidden form control to obtain the url and form url of the first two pages. Php uses the hidden form control to obtain the URLs of the first two pages. The form url encountered a similar problem during the learning process: for example, the background wanted to be like this: however, php hides the form control to obtain the url of the first two pages.
I encountered a similar problem during my learning process:
For example, the background is intended to be like this:
However, it is actually like this:
Solution:
Hide form controls
In this way, the value of $ _ SERVER ['http _ referer'] seems to be saved to $ _ POST [prevurl] temporarily.
In fact, the principle of this method is to post the previous url to another place through the post method, but this post is the current page.
In subsequent development, the new article will have a select Tag. if you enable the select tag disabled, the selected value cannot be post, so I used the den spoofing method again and submitted it in the dark.
How can I obtain the URL of the submitted page through php?
PHP $ _ SERVER ['http _ referer']
Use $ _ SERVER ['http _ referer'] to easily get the address of the previous page linked to the current page.
$ _ SERVER ['http _ referer'] is valid only for pages accessed through </a> hyperlinks and POST or GET forms.
PHP uses URL to pass variables. can I submit a variable without using a form?
Except for images, you can use URLs to pass variables.
The method is as follows: a. php? A = 123
Use $ _ GET ['A'] to output
Can I use a. php? A = 123 & B = 456 & c = 789
Echo $ _ GET ['A'] 123 echo $ _ GET ['B'] 456
Write a function to filter out the best variables to ensure the security of the webpage.
In fact, if GET is used, you can use post to get the values in the form. if not, you can check whether the post and GET settings are opened.
I encountered a similar problem during my learning process: for example, I wanted to make it in the background: but in reality, I...