printing the parameters out of an URL
| From: | Andrej Trobentar | Date: | Wed, 31 May 2000 18:14:31 +0000 |
| Subject: | printing the parameters out of an URL | ||
| Groups: | php.general | ||
| Request: | Send a blank email to php-general+get-745@lists.php.net to get a copy of this message | ||
After i submit a from (using the post method) i get an URL like this:
http://nora.sk-branik.si/andrej/delete.html?name=COMPANY&value=rikom&name=FIRST_NAME&value=sergej&name=LAST_NAME&value=godina&name=ADDRESS&value=mladinska+32b&name=PHONE&value=%2B386+2+220+88+54&name=CELLULAR_PHONE&value=%2B386+609+655+691
I wannt to display this parameters like this:
COMPANY : rikom
FIRST_NAME : sergej
....
How do i do that?
I cant do : <?php echo $name . " : ". $value ?> because then i get only
the last name and value printed. I don't know if i can use arrays for
that, my code looks like this (just a section of it) :
// Prints the first record from the database
for ( $i = 1; $i <= $ncols; $i++ ) {
$column_name = OCIColumnName($stmt,$i);
$column_value = OCIResult($stmt,$i);
print $column_name . ' : ' . $column_value . "<BR>";
print '<FORM method=get action="delete.html">';
print '<INPUT type="hidden" name="name" value="'.
$column_name
.'">';
print '<INPUT type="hidden" name="value" value="'.
$column_value
.'">';
}
print '<INPUT type="submit" value="delete this record">';
print '</FORM>';
I would like to pass the parameters like this :
print '<INPUT type="hidden" name="name[i]" value="'.
$column_name .'">';
...so the name would be an array. Is this possible? If yes, how?
Sorry for the long explenation i would be happy i someone could help
me.Thanks!