Target an iframe with a HTML Post with jQuery

前端 未结 7 2269
遥遥无期
遥遥无期 2020-12-08 07:50

If I\'m using jQuery or JavaScript to do a post, how can I make it target an iframe rather than the current page?

jQuery.post( 
    url, 
    [data], 
    [c         


        
7条回答
  •  半阙折子戏
    2020-12-08 08:31

    You can do this via a regular form:

    You can then use jQuery to submit the form:

    $("#formid").submit();
    

提交回复
热议问题