$ (Jquery) undefined

$ (Jquery) undefined

Hi,

I read a couple of posts to solve the $ undefined error, replacing the <src> link to include the jquery file.

First used the local:
<script type="text/javascript" src="1.7.2.jquery.min.js"></script> 

Then used the external:
<script type="text/javascript" src=" http://code.jquery.com/jquery-1.10.1.min.js"></script> 

Get  undefined on line 8: $
$.getJSON("/data2.json", function(data)


I would appreciate any assistance..

<!DOCTYPE html>
<html>
<head>
    <title>Test - Reading data in JSON format</title>
    <script type="text/javascript" src=" http://code.jquery.com/jquery-1.10.1.min.js"></script>
    <script type="text/javascript">
        function read_json() {
            $.getJSON("/data2.json", function(data) {
                alert("My data: " + data["mydata"]);
                $.each(data["prime"], function(idx,prime) {
                    alert("Prime number: " + prime);
                });
            });
        }
    </script>
</head>
<body onload="read_json();">
</body>
</html>