링크 : http://www.w3schools.com/jsref/jsref_regexp_source.asp 

Definition and Usage

The source property returns the text of the RegExp pattern.

Syntax

RegExpObject.source


Browser Support

Internet Explorer Firefox Opera Google Chrome Safari

The source property is supported in all major browsers.


Example

Example

Return the text of the RegExp pattern:

<script>

var str="Visit W3Schools";
var patt1=/W3S/g;
document.write("The text of the RegExp is: " + patt1.source);

</script>

Try it yourself »

저작자 표시 비영리 변경 금지
신고
posted by 뚱2