검색에 사용되는 변수에서 특수문자 제거 및 길이제한 추가

This commit is contained in:
chicpro
2014-03-12 10:42:03 +09:00
parent ab37de4292
commit 2d13c3b4b4

View File

@ -225,13 +225,14 @@ if (isset($_REQUEST['sfl'])) {
if (isset($_REQUEST['stx'])) { // search text (검색어)
$stx = trim($_REQUEST['stx']);
if ($stx)
$qstr .= '&stx=' . urlencode($stx);
$qstr .= '&stx=' . urlencode(cut_str($stx, 20, ''));
} else {
$stx = '';
}
if (isset($_REQUEST['sst'])) {
$sst = trim($_REQUEST['sst']);
$sst = preg_replace("/[\<\>\'\"\%\=\(\)\s]/", "", $sst);
if ($sst)
$qstr .= '&amp;sst=' . urlencode($sst); // search sort (검색 정렬 필드)
} else {