n

문의합니다.

http://www.sir.co.kr/bbs/tb.php/g4_skin/9867 이 스킨을 썼는데요...
 
한 페이지에 세개게시판의 최신글에 똑같은 new_img1스킨을 쓰니 첫번째 게시판 최신글은 제대로 나오고 두번째 게시판 최신글부터 아래와 같은 에러가 뜹니다. 무슨 이유인지요? 답장 부탁드립니다.
 
Fatal error: Cannot redeclare showtextintags() (previously declared in E:\Vhost\WebRoot\tbci\www\skin\latest\new_img\latest.skin.php:76) in E:\Vhost\WebRoot\tbci\www\skin\latest\new_img\latest.skin.php on line 76

댓글 5개

re =는 다시
declare = 선언
즉 중복선언된 경우입니다.

showtextintags() 함수를
latest.skin.php 에서 잘라내시고
latest.lib.php 에 붙여넣으시고 업로드.
latest.skin.php

<?##########################################
function showtextintags($text)
{
$text = preg_replace("/(\<script)(.*?)(script>)/si", "dada", "$text");
$text = strip_tags($text);
$text = str_replace("<!--", "<!--", $text);
$text = preg_replace("/(\<)(.*?)(--\>)/mi", "".nl2br("\\2")."", $text);
return $text;
}
##########################################
?>

지우시고

latest.lib.php
에 아무 곳에나
붙여 넣으세요

<?##########################################
function showtextintags($text)
{
$text = preg_replace("/(\<script)(.*?)(script>)/si", "dada", "$text");
$text = strip_tags($text);
$text = str_replace("<!--", "<!--", $text);
$text = preg_replace("/(\<)(.*?)(--\>)/mi", "".nl2br("\\2")."", $text);
return $text;
}
##########################################
?>
고맙습니다..^^ 수고하셨어요~
다른 분들도 쓰시다가 에러 부분이 있을것 같은데 다시 수정판을 올리시면 않될까요? 귀찮으시면 제가 대신 올려드릴께요^^
if(!function_exists('showtextintags'))
{
function showtextintags($text)
{
$text = preg_replace("/(\<script)(.*?)(script>)/si", "dada", "$text");
$text = strip_tags($text);
$text = str_replace("<!--", "<!--", $text);
$text = preg_replace("/(\<)(.*?)(--\>)/mi", "".nl2br("\\2")."", $text);
return $text;
}
}
댓글을 작성하시려면 로그인이 필요합니다.

그누보드4 관련 질문은 QA 로 이전됩니다. QA 그누보드4 바로가기 기존 게시물은 열람만 가능합니다.

+
제목 글쓴이 날짜 조회
06-07-29 조회 1,630
06-07-29 조회 1,641
06-07-29 조회 1,691
06-07-29 조회 1,544
06-07-29 조회 1,547
06-07-29 조회 1,601
06-07-29 조회 1,377
06-07-29 조회 1,647
06-07-29 조회 1,728
06-07-29 조회 1,199
06-07-29 조회 1,266
06-07-29 조회 1,353
06-07-29 조회 1,206
06-07-29 조회 1,598
06-07-29 조회 1,668
06-07-29 조회 1,602
06-07-29 조회 1,603
06-07-29 조회 1,494
06-07-29 조회 1,598
06-07-29 조회 1,699