Home » Interview Q&A » Archive by categoryJavaScript Interview Questions

Youtube thumbline image instead video Iframe

Youtube thumbline image instead video Iframe Hello folks, Today I want to share one of the amazing concept how can we use Youtube thumbline image instead video Iframe!! Because sometime youtube Iframe will take more time to get load though our whole page has been loaded at client side...
Continue reading

getElementById vs getElementsByName vs getElementsByTagName

Today we will discuss regarding getElementById vs getElementsByName vs getElementsByTagName in JavaScript. getElementById() : The getElementById() method returns the element that has the ID attribute with the specified value. This method is one of the most common methods in the HTML DOM, and is used almost every time you...
Continue reading

JavaScript String Object Property

Hello folks, today we will discuss about JavaScript String Object Property with examples. •  JavaScript constructor Property The JavaScript constructor property returns function that created the String object’s prototype Example: var str = ‘Hello’; alert(str.constructor); Live Demo: JavaScript String Object Properties-contructor • JavaScript length Property The JavaScript length property...
Continue reading

JavaScript Error Handling

JavaScript Error Handling is same as java and C#. JavaScript Error Handling can be achieved by writing try..catch. Syntax of JavaScript Error Handling try..catch block: try { //Run some code here } catch(err) { //Handle errors here } Error Handling   Example 1 Error Handling   Example 2  
Continue reading

Mathematical Constants in JavaScript

Mathematical Constants in JavaScript are as bellow: Math.E //2.718281828459045 Math.PI //3.14 Math.SQRT2 //1.414 Math.SQRT1_2 //0.707 Math.LN2 //0.693 Math.LN10 //2.302 Math.LOG2E //1.442 Math.LOG10E //0.434
Continue reading

JavaScript Math Object

The Math object is  to perform mathematical operation on client side in JavaScript. var x = Math.PI; // Returns PI var y = Math.sqrt(16); // Returns the square root of 16 Let have some detailed information about JavaScript Math Object: JavaScript abs() Method Math.abs(-2.57);    // 2.57 JavaScript...
Continue reading

isNaN function in JavaScript

The isNaN function in JavaScript determines whether a value is an illegal number (Not-a-Number). This function returns true if the value is NaN, and false if not. Examples: [crayon-5b74075eb7186616291173/]  
Continue reading

The content is copyrighted to technothirsty.com and may not be reproduced on other websites without permission from the owner.You may contact us using the information below.