Can't insert js programmatically if it uses [removed]

后端 未结 4 2062
别跟我提以往
别跟我提以往 2021-01-22 23:12

I am trying to insert js files programmatically, using jquery and something like this:

var script = document.createElement( \'script\' );
script.type = \'text/ja         


        
4条回答
  •  悲哀的现实
    2021-01-22 23:44

    Document.write is ONLY for synchronous tasks when the html is loaded (for the very first time), never for asynchronous tasks like the one you are trying to do.

提交回复
热议问题