1 개요[ | ]
- PHP addslashes()
- DB 질의, 자바스크립트 연동에서의 오류를 방지하기 위해 슬래시를 추가한다.
- MySQL 사용 시에는 mysql_real_escape_string() 사용을 권장한다.
PHP
Copy
$str = "Is your name O'reilly?";
echo addslashes($str);
# Is your name O\'reilly?
2 같이 보기[ | ]
- PHP stripslashes()
- PHP addcslashes()
- PHP mysql_real_escape_string()
- PHP htmlspecialchars()
- PHP quotemeta()
- PHP get_magic_quotes_gpc()
- 함수 addslashes()
3 참고[ | ]
편집자 Mywikier Jmnote Jmnote bot
로그인하시면 댓글을 쓸 수 있습니다.