click jquery call not working on button click

I am trying to write a simple code as follows:

        <script src="" />
        $("#submitQuery").click(function() {
        <label for="geo_location"> Enter location here: </label>
        <input id="geo_location" type="text" name="geo_location" required />
        <button id="submitQuery">Find out</button>
        <div id="test"></div>

However, clicking the button doesn't do anything. Where am I wrong here?

Answers 1

  • <script src="" /> </script>
             $("#submitQuery").click(function() {

    try miss the ready function..

Related Articles