검색결과 리스트
글
링크 : 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
 
 
 
 ![]()
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>
var str="Visit W3Schools";
var patt1=/W3S/g;
document.write("The text of the RegExp is: " + patt1.source);
</script>
Try it yourself »
'JavaScript > JavaScript' 카테고리의 다른 글
| [javascript] 브라우저 확인하기 (0) | 2012.11.28 | 
|---|---|
| [javaScript] javascript 함수와 스코프 체인 (0) | 2012.11.07 | 
| [Javascript] window.onerror (0) | 2012.10.31 | 
| [javascript] 천단위 숫자 찾아주는 정규표현식 (0) | 2012.09.22 | 
| [Javascript] UTF-8 인코딩 관련 (0) | 2012.09.21 | 

RECENT COMMENT