Can I use arrays here???

Discussion in 'PHP' started by dkin69, Apr 22, 2006.

  1. #1
    I am trying to make it easy for me to update my database so I would like to know if I can use arrays.

    Basically I will have 12 columns to update, each column a different item, each item a different level. if any of these levels are higher than that of the person updating then I do not want it passed.

    So eg

    if Jim is level 5 and has 3 items at level 3 and 2 at 6 he can only equip 3 items.

    anyone know?

    thanks

    Turk
     
    dkin69, Apr 22, 2006 IP
  2. digitalpoint

    digitalpoint Overlord of no one Staff

    Messages:
    38,334
    Likes Received:
    2,613
    Best Answers:
    462
    Trophy Points:
    710
    Digital Goods:
    29
    #2
    Probably will want to use a many to many relationship for your database schema.

    If you want to do it in PHP arrays, I would recommend storing things in the database with the serialize() functions.
     
    digitalpoint, Apr 23, 2006 IP