Possible duplicate:Why use document.write?
Given the negative effects of document.write (), why are most tracking / marketing tags written using document.write ()?
I thought about it quite a bit, and the only respectable idea that I came up with is that by writing it on the client side, we guarantee that the browser will not try to cache the resource. This is it? Any other ideas?
, , , - . " " , , , v3-, , .
[edit] "v3", Firefox 3, Netscape 3. Netscape , , 11.
, document.write, script, , . : http://www.stevesouders.com/blog/2009/04/27/loading-scripts-without-blocking/
, -, ...? , , - , , IMG- document.write -written IMG.
document.write
, , script . ( ) script (, URL-, ) , HTTPS. https-, https://omniture.com/xxx, http://omniture.com/yyy. javascript, HTML. , , , , " , ", , , , .
https://omniture.com/xxx
http://omniture.com/yyy
. script, , script. script document.getElementsByTagName("script") HTML script URI, , URI (http://example.com/blah.js#foo) DNS. , script, . document.write . (<script async>)
document.getElementsByTagName("script")
http://example.com/blah.js#foo
<script async>
Source: https://habr.com/ru/post/1739913/More articles:Transaction isolation when selecting, inserting, deleting - databasePython list like * args? - pythonRx: объединение нескольких IObservable веб-запросов - c#C # Thread-safe Extension Method - multithreadingClient-side validation with modelless view in ASP.NET MVC 2 - asp.net-mvc-2What will this B-tree look like? - b-treeЗапуск приложения GUI в режиме службы Windows - user-interfaceWF4: receive argument / variable information during downtime - workflow-foundationЕсли утверждение недействительно - c++NSDate - GMT on iPhone - dstAll Articles