제목 입력값에 ' 혹은 " 포함된 경우 처리
이름 윤교수 날짜 2018-12-31 조회 11336
1. codeigniter3에서 input type=text의 value에 초기화할때

   $title = htmlspecialchars($title);     // It\'s  --> It & acute ;  s

2. 값 저장할 때 : insert, update 하기전에

   $title = addslashes($title);       // It's  --> It\'s

3. 값  표시할 때 :

   $title = stripslashes($title);      // It\'s  --> It's


Copyright 2002-2025 by Induk University Gamejigi, 교수 윤형태 (yht@induk.ac.kr). All right reserved.