Skip to content
Advertisement

PHP/Postman – How to populate the $Get

I am trying to do a Get request with Postman to a PHP script. But it doesn’t seem to populate the $_GET array? Why is this happening?

http://localhost/download.php/game

JavaScript

Advertisement

Answer

If you are not sure whether $_GET[‘game’] is empty or not try using var_dump($_GET[‘game’] to first check the content of the array. Also you will need to include the get parameter within the link somewhat like this: yourdomain/download.php?game=variable. Also change your double quotation marks when trying to access $_GET to single marks.

User contributions licensed under: CC BY-SA
4 People found this is helpful
Advertisement