SitePoint Sponsor

User Tag List

Results 1 to 2 of 2
  1. #1
    SitePoint Enthusiast
    Join Date
    Nov 2004
    Location
    griffith
    Posts
    72
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Allow Multiple Products in Array

    Newbie question. I have an array that currently outputs a single product:
    HTML Code:
    "Product" => $product_code
    If I want to allow for multiple product_codes (in an instance where user chooses more than one product), how would I change the array to allow for multiple products?

  2. #2
    Follow Me On Twitter: @djg gold trophysilver trophybronze trophy Dan Grossman's Avatar
    Join Date
    Aug 2000
    Location
    Philadephia, PA
    Posts
    20,578
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)
    Arrays can contain arrays

    PHP Code:
    $array['product'] => array('product1''product2''product3'); 


Bookmarks

Posting Permissions

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