How to get my insert.php url in jquery?

Question

I want to save my form data via jquery but i can’t able to access it in my script.Can anyone help me.
URL access in script: url: ‘admin.php?page=insert.php’,

My script

$(function () {
        $('form').on('submit', function (e) {
          e.preventDefault();
          var schema_key = $("#schema_key").val(); 
          $.ajax({
            type: 'post',
            url: 'admin.php?page=insert.php',
            data: schema_key,
            success: function () {
              alert('form was submitted');
            }
          });

        });

      });

--------------------------------------------------

>>> Share a link to this question, just copy and paste the code bellow on your web page <<<

<a href="https://www.wptricks.com/question/how-to-get-my-insert-php-url-in-jquery/">

How to get my insert.php url in jquery?</a>
0
shpwebhost 3 years 0 Answers 133 views 0

Leave an answer