How can jQuery load some html and append it to the <body> element?

后端 未结 5 489
小蘑菇
小蘑菇 2020-12-10 10:37

I tried the following:

$.load(\"Views/chatBox.html\").appendTo(\'body\')

Console Output:

TypeError: $.load is not a functio         


        
5条回答
  •  南方客
    南方客 (楼主)
    2020-12-10 11:14

    I dont understand why placing container at the bottom of body and loading external page into that is not what you need?

    What you can try is this:

    
    

    But im not 100% sure about this code... :)

提交回复
热议问题