title: Creating a Menu from JSON
body: <p>I am trying to create a dynamic menu using jQuery UI.</p>
  
  <p>I will be fetching entries from a JSON file and creating my menu items.I decided to do a small demo before i try this on a larger scale.Here's my fiddle which works the way i want it to work. Now I cant get this to work with a JSON file.</p>
  
  <p><strong><a href="http://jsfiddle.net/marsone/9uhc3/" rel="nofollow">WORKING FIDDLE</a></strong></p>
  
  <p>Here is the JSON</p>
  
  <pre><code>var JSON = 
      {
         menu: 
            [
               {name: 'Croatia', link: '0', sub: null},
               {name: 'England', link: '1', sub: 
                  [
                     {name: 'Arsenal',link: '0-0', sub: null},
                     {name: 'Liverpool',link: '0-1', sub: null},
                     {name: 'Manchester United',link: '0-2', sub: null}
                  ]
               },
               {name: 'Spain', link: '2', sub: 
                  [
                     {name: 'Barcelona',link: '2-0', sub: null},
                     {name: 'Real Madrid',link: '2-1', sub: null}
                  ]
                },        
                {name: 'Germany', link: '3',sub: 
                  [
                     {name: 'Bayern Munich',link: '3-1', sub: null},
                     {name: 'Borrusia Dortmund',link: '3-2', sub: null}
                  ]
                }
            ]
      }
  </code></pre>
  
  <p>How can i design my entire menu using the values from the JSON where the Li's will be something like the following.</p>
  
  <pre><code>&lt;li&gt;&lt;a href="#3-2"&gt;Borrusia Dortmund&lt;/a&gt;
  &lt;/li&gt;
  </code></pre>
  
  <p><strong>EDIT:</strong> The question may sound like i have not tried anything, but i have. its just the JSON part which i cannot understand, Jsfiddle does not read it properly. I am wondering if my jSON is not formatted properly. Any help would be appreciated</p>