|
|
|
20년 전
|
조회 1,302
|
|
|
|
20년 전
|
조회 1,966
|
|
|
|
20년 전
|
조회 2,090
|
|
|
|
20년 전
|
조회 1,363
|
|
|
|
20년 전
|
조회 1,302
|
|
|
|
20년 전
|
조회 1,421
|
|
|
|
20년 전
|
조회 1,460
|
|
|
|
20년 전
|
조회 1,314
|
|
|
|
20년 전
|
조회 1,448
|
|
|
|
20년 전
|
조회 1,302
|
|
|
|
20년 전
|
조회 1,323
|
|
|
|
20년 전
|
조회 1,391
|
|
|
|
20년 전
|
조회 1,373
|
|
|
|
20년 전
|
조회 1,470
|
|
|
|
20년 전
|
조회 1,635
|
|
|
|
20년 전
|
조회 1,483
|
|
|
|
20년 전
|
조회 1,441
|
|
|
|
20년 전
|
조회 1,303
|
|
|
|
20년 전
|
조회 1,328
|
|
|
|
20년 전
|
조회 1,294
|
댓글 9개
홑따옴표가 들어가면 문제가 있습니다.
597줄 위에 $file = addslashes($file); 넣으면 해결 될것 같습니다.
========================================수정전
if (preg_match($cfg[image_extension], $file))
// 3.36
return "<a href=\"javascript:;\" onclick=\"image_window('./data/file/$board[bo_table]/$file', $source_width, $source_height);\"><img src='./data/file/$board[bo_table]/$file' width='$width' height='$height' border=0></a><p>";
else if (preg_match($cfg[flash_extension], $file))
return "<embed src='./data/file/$board[bo_table]/$file' width='$width' height='$height'></embed><p>";
else if (preg_match($cfg[movie_extension], $file))
return "<embed src='./data/file/$board[bo_table]/$file'></embed><p>";
=========================================수정후
if (preg_match($cfg[image_extension], $file))
// 3.36
return "<a href=\"javascript:;\" onclick=\"image_window('./data/file/$board[bo_table]/$file', $source_width, $source_height);\"><img src='./data/file/$board[bo_table]/$file' width='$width' height='$height' border=0></a><p>";
$file = addslashes($file); //<--요거 삽입했거든요
else if (preg_match($cfg[flash_extension], $file))
return "<embed src='./data/file/$board[bo_table]/$file' width='$width' height='$height'></embed><p>";
else if (preg_match($cfg[movie_extension], $file))
return "<embed src='./data/file/$board[bo_table]/$file'></embed><p>";
====================================================
질답란에 보니까 홑따옴표 에러 접근 방법이 여러가지 있던데.. 어떻게 해야 할지
난감합니다. 여기 저기 다른 php 게시판 공부 게시판에 보니까 '가 들어가면
php 구문에 영향을 미쳐서 에러 난다고 하던데 그누에선 어떻게 처리해야할지..
addslashes --> 이 함수 사용하는 건 맞는 거 같은데요.. 다시 답변 부탁드리겠습니다
꾸벅 ( _ _)
if (preg_match($cfg[image_extension], $file)) { // <--- 요거
// 3.36
$file = addslashes($file); //<--요거
return "<a href=\"javascript:;\" onclick=\"image_window('./data/file/$board[bo_table]/$file', $source_width, $source_height);\"><img src='./data/file/$board[bo_table]/$file' width='$width' height='$height' border=0></a><p>";
} // <--- 요거
else if (preg_match($cfg[flash_extension], $file))
return "<embed src='./data/file/$board[bo_table]/$file' width='$width' height='$height'></embed><p>";
else if (preg_match($cfg[movie_extension], $file))
return "<embed src='./data/file/$board[bo_table]/$file'></embed><p>";
====================================================
위 같이 하면 해결 될것 같습니다....
천상 각 ...update.php의 최 상단에 일일이 찾아서 $변수 = addslashes($변수)
이렇게 입력해버릴가 생각 중입니다. 생고생할 거 같아요ㅠㅠ
본문보기 에서 이미지 누르면 빈 이미지가 뜨는 문제좀에 대해
조언 좀 해주세요. 요즘 그누 에러 때문에 많이 배우기 하나
쉽지 않네요 ㅠㅠ 고맙습니다. 텍와이드님 관심 가져주셔서요..
사이트 주소를 알려주시면 확인 해 드리겠습니다.
공개하시기 뭐 하시면 쪽지로 주셔도 됩니다.
그리고 addslashes()는 필요한 부분은 이미 사용 되고 있습니다.
if (!get_magic_quotes_gpc()){
$wr_subject = addslashes($wr_subject);
$wr_content = addslashes($wr_content);
$wr_name = addslashes($wr_name);
} 라고 입력하니까 해결이 되네요. ...update.php파일들은 일일이
이렇게 찾아 입력하는 수 밖에 없을 거 같습니다.
본문보기에서 이미지 빈상자만 뜨는 건 다시 알려주신대로 해도 여전히
허연 빈상자만 뜹니다.
이것도 addslashes 함수와 상관이 있나요? 어디서 수정을
해야 할지요? 뭐가 잘못된는지 참...
한글로 됐을 경우 먹히지 못하는 서버가 있지요.
어떤 경우인지 직접 접하기 전에는 뭐라 말 할 수가 없네요.
뚝딱거리고 있거든요. 지금 gbview.php를 뚜딱거리고 있습니다.
여기저기 미친듯이 뚝딱거리고 있습니다..^^
아무튼 텍와이드님 같이 관심 가져 주신분도 없고 정말 고맙습니다.
언제 뉴질랜드 오심 술한잔 대접하겠습니다. 증말입니다.^^
즐거운 하루 되세요..