Quantcast
Channel: Active questions tagged html - Stack Overflow
Viewing all articles
Browse latest Browse all 74793

how to make a form pop up on the same page after clicking an anchor tag with jquery

$
0
0

I want a code for a form inside a div to be triggered when I click an anchor tag. when I click the hyperlink it says this in the console:

Uncaught TypeError: $(...).draggable is not a function

I dont know what I'm doing wrong here with this function?

<script>
  $(function() {
    $("showForm").on("click", function() {
      $("#draggable").toggle();
    });
  });
</script>


<div>
  <a href="#" id="showForm"><h3>New Post</h3></a>
</div>


<div id="draggable" class="drag postblock">
  Post No.
  <img src="images/cross.png" alt="X" id="qrClose" class="extButton" title="Close Window">
  <form name="form1" method="post" action="index.php" enctype="multipart/form-data">
  <div>
  <textarea name="post" cols="48" rows="4" wrap="soft" tabindex="0" placeholder="Entry"></textarea>
  </div>
  <div>
  <input type="file" id="qrFile" tabindex="0" size="19" title="Upload file">
  <input type="submit" name="submit" value="Post">
  </div>
  </form>
</div>

Viewing all articles
Browse latest Browse all 74793

Latest Images

Trending Articles



Latest Images

<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>