شی سراسری
بازگشت به صفحه اصلی
بازگشت به صفحه مقاله
دو ستونی
دو سطری
اجرای کد RUN »
<!DOCTYPE html> <html> <body> <h2>JavaScript Functions</h2> <p>In HTML the value of <b>this</b>, in a global function, is the window object.</p> <p id="demo"></p> <script> var x = myFunction(); function myFunction() { return this; } document.getElementById("demo").innerHTML = x; </script> </body> </html>