Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
240 views
in Technique[技术] by (71.8m points)

html - After a XMLHttpRequest to add content to page, How can I access the inner javascript?

On the webpage I am making, I have made a dynamic loader for the main contents. It uses a XMLHttpRequest to get an html file, then sets the innerHTML of a div to the contents of the file. The problem is, any script tags are not run. Any functions in them are not runnable. Is there any way I can force this javascript to run?

question from:https://stackoverflow.com/questions/65622971/after-a-xmlhttprequest-to-add-content-to-page-how-can-i-access-the-inner-javasc

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Answer

0 votes
by (71.8m points)
Waitting for answers

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...