이 함수의 사용법은? 정보
이 함수의 사용법은?본문
오류가 나는곳의 주소를 알려주시면 더 빠르고 정확하게 답변 받을 수 있습니다.
오류 주소 :
<?php
$subject = "abcdef";
$pattern = '/^def/';
preg_match($pattern, substr($subject,3), $matches, PREG_OFFSET_CAPTURE);
print_r($matches);
?>
웨에서 PREG_OFFSET_CAPTURE 가 무엇을 뜻하는가요?
오류 주소 :
<?php
$subject = "abcdef";
$pattern = '/^def/';
preg_match($pattern, substr($subject,3), $matches, PREG_OFFSET_CAPTURE);
print_r($matches);
?>
웨에서 PREG_OFFSET_CAPTURE 가 무엇을 뜻하는가요?
댓글 전체
PREG_OFFSET_CAPTURE
If this flag is passed, for every occurring match the appendant string offset will also be returned. Note that this changes the return value in an array where every element is an array consisting of the matched string at index 0 and its string offset into subject at index 1.
http://kr2.php.net/manual/en/function.preg-match.php
여기 참고해보세요
If this flag is passed, for every occurring match the appendant string offset will also be returned. Note that this changes the return value in an array where every element is an array consisting of the matched string at index 0 and its string offset into subject at index 1.
http://kr2.php.net/manual/en/function.preg-match.php
여기 참고해보세요