'sub()' Example : sub « Javascript Methods « JavaScript Reference

'sub()' Example

    
<html>
<body>
<button onclick="var myS = new String('Sample String'); 
                 document.write('regular string'+myS.sub());">
sub me
</button>
</body>
</html>

    
      
      








Related examples in the same category

1.'sub()' Syntax, Parameters and Note
2.'sub()' is applied to