accessing part of a variable using its index

you can access part of a string variable using its index[1]


var my_string = "string";
var first_letter_of_my_string = my_string[0];


Other Items in javascript
Page Views

This page has been viewed 147 times.

Search Code
Search Code by entering your search text above.

This is my test area for webdev. I keep a collection of code snippits here, mostly for my reference. Also if i find a good site, i usually add it here.