Olası Çoğalt konak fonksiyonunu başvurulması:
JavaScript function aliasing doesn't seem to workJavaScript: Yerel değişkeni yoluyla
neden değil bu iş? Firefox'ta Uncaught TypeError: Illegal invocation
... ve:
function foo() {
var g = document.getElementById;
g('sampleID');
}
Bu hata Chrome'da atılır Error: uncaught exception: [Exception... "Illegal operation on WrappedNative prototype object"
olsa IE9 beta çalışır
!!
Gösteri:http://jsfiddle.net/ugBpc/
olası yinelenen http: // stackoverflow. com/questions/1007340/javascript-function-aliasing-doesnt-work-to-work) –
Denediniz mi? g.call (document, 'sampleID'); '?? – Pointy
@Pointy Hayır, daha önce düşünmedim :) –