html - Problem in sending values between pages in PHP -


i want send data 1 page other via form in php. in initial page have included following php script generates input form hidden fields. names of these hidden fields generated php:

<?php   echo     "<form class='available-form' name='available_os' method='get' action='process-results.php'>";   echo        "<input type='hidden' name='$software'></input>";   echo        "<input type='hidden' name='$version'></input>";   echo        "<input type='submit' name='available-button' value='find available libraries software'></input>";   echo     "</form>"; ?> 

in second page, named process-results.php, names of these hidden fields via $_get method of course using $_get[$software] , $_get[$version] wouldn't work...can tell me if there solution issue or if there better alternative? in advance

instead of "<input type='hidden' name='$software'></input>";, should use "<input type='hidden' name='software' value='".$software."'></input>"; each. way, can use $_get['software'] retrieve value. each of hidden inputs.


Comments