javascript - Get the url parameter or the part of the url after the question mark (?) of an included php file
I basically have this "info.php" file included in another php file which is "main_page.php". By clicking a link in the page, the link sends a url parameter to the "info.php" file through javascript by reloading the page, giving it a new url. The "info.php" file then, for instance, becomes "info.php?student=1" which is, again, to be clear, included inside the "main_page.php" file. I've researched for solutions but what I only found are those javascripts and php scripts that gets the current url in the address bar.
Is there a way to do this, getting the new url of an included php file? If there is, then please forgive me for my dumbness and irresponsibly inadequate researching. Thank you so much.
Answer
Solution:
This is what you are looking for.
Here is the documentation
Answer
Solution:
You should be able to access your URL query variables through the global $_GET array.