Edison
Edison

Reputation: 4291

jquery not working in my VS2013

I have made following very simple code just to test few things.My following code is not working in my website project in VS2013 although it is working fine in jsfiddle.net.what is happening ?

HTML:

 <p>Name:</p>
    <input type="text" />
    <p>Age:</p>
    <input type="text" />
    <p></p>
    <input type="button" id="btn" value="Submit" />

JS:

<script src="Scripts/jquery-2.1.1.min.js">
        $(document).ready(function () {
            $("#btn").click(function () {
                window.alert("Hi Guys");
            });
        });
    </script>

Upvotes: 0

Views: 692

Answers (1)

aleha_84
aleha_84

Reputation: 8539

<script src="/Scripts/jquery-2.1.1.min.js"></script>
<script>
$(document).ready(function () {
    $("#btn").click(function () {
        alert("Hi Guys");
    });
});
</script>

Upvotes: 2

Related Questions