I'm trying to validate user information on our registration form. I'm relatively new to JQuery so im having troubles getting the script to actually run and check the information. Right now im just testing to see if the Email Address field is empty. Once i can check for that i should be able to handle generating the rest of the error checking.

This is our **registration.html** file

```
 <html>
<head><title>Registration Form: jQuery</title>

<script type="text/javascript" src="script/jquery-1.8.2.min.js"></script>
<script type="text/javascript" src="script/my_script.js"></script>
</head>
<body>

    <form id="myForm"  method="POST">
        Email Address: <input type="text" id="email"/><br />
        Password: <input type="password" id="pass"/><br />
        First Name: <input type="text" id="fName"/><br />
        Last Name: <input type="text" id="lName"/><br />
        <button id="submit">register</button>
    </form>

    <div id="ack"></div>

    <script src="registration.js"></script>

</body>

```

And this is the **registration.js** file I've been working on

```
$(document).ready(function(){
$("#submit").click(function(){
    if($("#email").val() = "")
    {
        alert("Email Address must not be empty.");
    }
    else
    {
        alert("Success");
    }

}); 
});

```

Any help would be appreciated. If it matters, we have been using Adobe PhoneGap Build to generate a mobile version of our site and I believe we used JQuery to connect to our database. Thanks!

***EDIT*** Its fixed!It was a combination of my If statement being incorrect and not properly linking to the JQuery library. The console option of chrome helped greatly. Thanks guys!