wheseven.blogg.se

Vbscript html examples
Vbscript html examples












vbscript html examples

So that is a one significant difference between JavaScript and JScript. But JavaScript recognises the temp variable and the object within the page having id "temp" as two entirely separate fields. So he treats as both of them are referring to one single object. The reason behind this is, in here JScript does not recognize the difference between var temp and document.getElementById('temp'). In here, JavaScript is working fine, but the JScript gives a error.

#VBSCRIPT HTML EXAMPLES CODE#

Let's declare a variable called temp in JavaScript code and create a object within the page having the field id as "temp".Īnd trying to set the value of object temp in the page to the value of variable temp.ĭocument.getElementById('temp').innerHTML = temp But in some situations JScript is not behaving like JavaScript. Microsoft thought of implementing their own version of JavaScript and they named it as JScript. Here is a simple example showing a text in a web page using JavaScript.Īctually JScript is just the Microsoft's version of JavaScript. Anyhow I don't want to remind you, now JavaScript is one of the most popular Scripting Languages. And the funny thing is, JavaScript got it named as JavaScript by Netscape as a marketing strategy to increase the popularity of JavaScript language. In that time Java was a very popular programming language through out the industry. JavaScript was originally developed by Netscape. Actually it has nothing to do with Java and these two are completely different from each other. I am pretty sure some of you must be thinking JavaScript has something to do with the Java programming language. These scripts can be integrated directly into the HTML code. JavaScript is a light weight and very simple Scripting Language that has Object Oriented capabilities and most importantly it is a cross platform Scripting Language. Sometimes you must have wondered what is this JavaScript and JScript, because their names even feel similar too. Those are JavaScript, JScript and VBScript. My last post was about Web Scripting using Scripting Languages and today I am going to write about three commonly using languages in Web Scripting.














Vbscript html examples