Need Help Parsing JSON code

Need Help Parsing JSON code

Hey guys. I am new to parsing JSON. I am trying to use jQuery to parse through a json file but it doesn't seem to be working .

I am using firebug to debug this. I can see that the data has been parsed from the $.parseJSON function, but when I hover over the json var it says "undefined"

Anyone know what I might be doing wrong here?? Below is my code

  1.      <script>
                $(function(){
                   
            
                $.getJSON('json.json', function (data) {
             var json = $.parseJSON(data);
             $("#result").html(json.name);
                
        
              
                });
               
                   });
                </script>
        </head>
        <body>
            <div id="result"></div>
        </body>
















Here is my JSON file


  1. { "name": "eldan" }