Results 1 to 2 of 2
  1. #1
    Join Date
    Nov 2005
    Posts
    40

    Unanswered: Pass variable to $row

    I am trying to store a variable from a mysql DB with :
    $row2=mysql_fetch_array($result);

    so that a single variable can be called with :

    echo $row2["product_id"];

    The only problem is that only with echo i can have access to the variable product_id and i cant use anything else.

    How can i store this variable to $x for example ???

    IS there any way or should i use any other function than mysql_fetch_array () ????

  2. #2
    Join Date
    Apr 2005
    Location
    Baltimore, MD
    Posts
    297
    How can i store this variable to $x for example ???
    PHP Code:
    $x $row2["productid"]; 

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •