string.valueOf() : valueOf : String JAVASCRIPT TUTORIALS


JAVASCRIPT TUTORIALS » String » valueOf »

 

string.valueOf()







The valueOf() method returns the primitive value of the object. In terms of an instance of a String object, this method returns the string itself.












<html>
    <script language="JavaScript1.1">
    <!--
    var myString = new String("Here is some random text.");

    document.write('The value of my string instance is: ' + myString.valueOf());

    document.close();

    -->

    </script>
</html>







HTML code for linking to this page:

Follow Navioo On Twitter

JAVASCRIPT TUTORIALS

 Navioo String
» valueOf