10.02.2018 Views

js_tutorial

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

Javascript<br />

<br />

JavaScript String strike() Method<br />

<br />

<br />

<br />

var str = new String("Hello world");<br />

alert(str.strike());<br />

<br />

<br />

<br />

Output<br />

Hello world<br />

sub()<br />

This method causes a string to be displayed as a subscript, as if it were in a<br />

tag.<br />

Syntax<br />

Its syntax is as follows:<br />

string.sub ( )<br />

Return Value<br />

Returns the string with tag.<br />

Example<br />

Try the following example.<br />

174

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!