JavaScript Tutorial





Español Français 中文 Deutsch Portuguese Japanese nederlands
   
 
Java-Script Tutorial
Introduction Introduction
Variables Variables
Operators Operators
Statements Statements
Loops Loops
Functions Functions
Objects Objects
Arrays Arrays
Cookies JS Cookies
Browser Objects Browser Objects
Form DOM Form DOM
Style Objects DOM Style Objects
Forums Ask Your Doubts
Scraps More about Javascript
Feedback Feedback
 




Object String Function


Tutorials Javascript

Topic

What are the methods of string object in javascript?



Explanation
An object is nothing but a class or file with a group of functions or methods. In javascript strings are stored as string objects. We can declare a string in either of the two ways

a) var sname = "testing string object";
b) var sname = new String("testing string object");

Both results in the same string object. String object contains some predefined function or methods that are extensively used in javascript.

String object has the following functions
a)length()
b)charAt()
c)indexOf()
d)lastIndexOf()
e)substring()
f)split()
g)toLowerCase()
h)toUpperCase()






A Note
Javascript (JS) is one of the most used languages in the world. Some times spelled as Java Script. Hope you enjoy this tutorial. Do send your feedback or suggestions on this javascript or java script tutorial. This is a copyright content.

Other Links

web hosting