Click to See Complete Forum and Search --> : [Resolved] [Resolved] Record Store tutorial


sxrxnrr
06-21-2003, 10:57 AM
I'm doing the Record Store tutorial found at the Macromedia web site but I'm having some trouble with the $HTTP_GET_VARS statement.
I'm using PHP 4.2.3


I've made a link to a PHP page like this: info.php?AlbumID=<?php echo $row_catalog['AlbumID']?>;

with 'AlbumID' coming from a recordset.
When I pass mouse pointer on the link, in the explorer status bar i can see the correct link (i.e.:http://localhost/RecordStorePHPStart/info.php?AlbumID=6) but when I try to acces it always sends me to the default value page.

In info.php page i've a recordset with SQL code:

SELECT *
FROM album, artist
WHERE album.ArtistID = artist.ArtistID AND AlbumID=colname

where colname is a variable defined with the following statement:

Name: colname
Default: 1
Runtime: $HTTP_GET_VARS['AlbumID']

Muntjewerf
06-27-2003, 02:48 PM
Eyz,
$HTTP_GET_VARS will not work unless you have register_globals set to ON in your php.ini (not recommended though). Since PHP version 4.1.0 $_GET was introduced, so try to use $_GET instead of $HTTP_GET_VARS.