Adding POST parameters before submit

前端 未结 7 870
情深已故
情深已故 2020-11-27 11:39

I\'ve this simple form:

相关标签:
7条回答
  • 2020-11-27 12:22

    You could do an ajax call.

    That way, you would be able to populate the POST array yourself through the ajax 'data: ' parameter

    var params = {
      url: window.location.pathname,
      time: new Date().getTime(), 
    };
    
    
    $.ajax({
      method: "POST",
      url: "your/script.php",
      data: params
    });
    
    0 讨论(0)
提交回复
热议问题