Help with json file

Discussion in 'JavaScript' started by bellcom, May 7, 2014.

  1. #1
    I am working on a menu here:
    http://racemeshtrucks.com/shop/menu-test3.html

    If you choose the "Dodge" icon it shows 3 instances of "Dodge-Ram-1500" and each displays a different year down below when clicked. So I did this wrong, how could I change this so the "Dodge-Ram-1500" only displays once with the 3 year options displayed below when clicked?

    Here is the section of the code in the json file:

    {
    "Brand": "Dodge",
    "Model": [
    {
    "Name": "Dodge-Ram-1500",
    "Year": "2006-2009",
    "Message": ""
    },
    {
    "Name": "Dodge-Ram-2500-3500",
    "Year": "2006-2009",
    "Message": ""
    },
    {
    "Name": "Dodge-Ram-2500-3500",
    "Year": "2010-2012",
    "Message": ""
    },
    {
    "Name": "Dodge-Ram-2500-3500",
    "Year": "2013-2015",
    "Message": ""
    }
    ]
    },


    Thanks!
     
    bellcom, May 7, 2014 IP
  2. bellcom

    bellcom Well-Known Member

    Messages:
    220
    Likes Received:
    47
    Best Answers:
    0
    Trophy Points:
    120
    #2
    Ok, I think I figured this out myself :)
     
    bellcom, May 7, 2014 IP