블로그를 설치하고부터 > 그누3질답

그누3질답

블로그를 설치하고부터 정보

그누보드 블로그를 설치하고부터

본문

블로그형 스킨 4차 수정판을 설치하고
설명서 나온 내용으로 수정을 하고 난뒤 부터
관리자 모드로 로그인 부분에서 접속이 안됩니다.

Fatal error: Call to undefined function: gotourl() in /home1/e6e3/public_html/gboard/bbs/admin/index.php on line 142


관련 내용은...

// 로그인중이라면
if ($_SESSION[ss_mb_id]) {
    $member = get_member($_SESSION[ss_mb_id]);
}    <-------------------------------------------------------142번입니다.

// 회원자료가 있다면
if ($member[0]) {
    // 읽지 않은 쪽지가 있다면
    $sql = " select count(*) from $cfg[table_memo]
              where me_recv_mb_id = '$member[mb_id]'
                and me_read_datetime = '0000-00-00 00:00:00' ";
    $row = sql_fetch($sql);
    $memo_not_read = $row[0];
} else {
    $member[mb_level] = $cfg[level_guest];
}

// 시간이 지난 접속은 삭제한다
$deltime = date("Y-m-d H:i:s", time() - (60 * $cfg[login_minutes]));
$sql = " delete from $cfg[table_login] where lo_datetime < '$deltime' ";
@mysql_query($sql);

if (isset($bo_table)) {
    $write_table = $cfg[write_table_prefix] . $bo_table; // 게시판 테이블 전체이름
    $board = sql_fetch(" select * from $cfg[table_board] where bo_table = '$bo_table' ");
    if ($board[0]) {
        $gr_id = $board[gr_id];
        if ($wr_id) {
            $write = sql_fetch(" select * from $write_table where wr_id = '$wr_id' ");
        }
    }
}

if ($gr_id) {
    $group = sql_fetch(" select * from $cfg[table_group] where gr_id = '$gr_id' ");
}

// 관리자인가?
$is_admin = is_admin($member[mb_id]);


그리고 관리자 모드를 다른 경로를 통해서 접속을 한뒤
게시판 수정을 하고 확인을 누르면

Fatal error: Call to undefined function: gotourl() in /home1/e6e3/public_html/gboard/bbs/admin/boardupdate.php on line 250

이렇게 뜹니다.

내용은...
mysql_free_result($res);

if ($w == '') {
    gotourl("./?doc=bbs/admin/boardlist.php&$qstr");
} else {
    gotourl("./?doc=bbs/admin/boardform.php&w=u&bo_table=$bo_table&$qstr");  <------250번
}
?>

어떻게 되었는지 궁급니다.

그리고 블로그에서도 달력이 안나오는 사항입니다.

Fatal error: Call to undefined function: array_fill() in /home1/e6e3/public_html/gboard/bbs/skin/board/blog/calendar.php on line 86

/*****
// 수정자 사이트 : www.ThreeS.org
// 그누보드 게시판에서 블로그형 스킨에 사용하기위해서 추가하는것
*****/
if(!$bo_table) $bo_table = "blog";
$sql = "select count(wr_id) as blog_count, conv(substring(wr_datetime, 9, 2), 10, 10) as blog_day
from {$cfg[write_table_prefix]}{$bo_table}
where wr_datetime>='$year-$month-01' and wr_datetime<='$year-$month-31 9'
group by left(wr_datetime, 10) ";
$result = sql_query($sql);
$write_blog = array_fill(1,$maxdate,-1);  <-------------------------------------86번입니다.

for ($i = 0; $row = mysql_fetch_array($result); $i++) {
$write_blog[$row[blog_day]] = $row[blog_count];
}
mysql_free_result($result);


어디가 잘못 된 것인지 궁금합니다.
  • 복사

댓글 전체

*****/
if(!$bo_table) $bo_table = "blog";

위 두줄 사이에 위 소스중 <?php와  ?>를 제외하고 넣으세요
다음처럼

*****/

// For PHP version < 4.2.0 missing the array_fill function,
// I provide here an alternative. -Philippe

function array_fill($iStart, $iLen, $vValue) {
  $aResult = array();
  for ($iCount = $iStart; $iCount < $iLen + $iStart; $iCount++) {
      $aResult[$iCount] = $vValue;
  }
  return $aResult;
}

if(!$bo_table) $bo_table = "blog";
http://man.phpschool.com/manual/en/function.array-fill.php
위의 array_fill 참조사이트에 보시면 php버전이 4.2.0 보다 작은곳에서 array_fill 을 사용할수있는 방법이 나와있군요.


<?php

// For PHP version < 4.2.0 missing the array_fill function,
// I provide here an alternative. -Philippe

function array_fill($iStart, $iLen, $vValue) {
  $aResult = array();
  for ($iCount = $iStart; $iCount < $iLen + $iStart; $iCount++) {
      $aResult[$iCount] = $vValue;
  }
  return $aResult;
}

?>
저도 그러류의 에러가 나왔는데요.....그건 버젼이 낮아서(PHP) array_fill함수를 이용하지 못한다구 한대요..--맞는지 모르겠지만.
그래서 저 경우는 서버를 직접관리 하기 때문에 아파치,php,mysql,gd까지 다 지우고 새로 깔았습니다.
날 꼬박 새우고...^.^;
무식이 유식을 따라잡을때도 있잖아요...
잘 몰라서 그냥  다 지우고 다시깔고 다시 설치하고 그 후....겨우 에러없이 돌아갑니다.
저 경우 오류 경험담이라면..
1) 로그인 오류
2) db접속 오류
3) 스킨 받아서 깔면....로그인 메뉴 설정이 수정도 안되고 삭제도 안되고
4) 무식하게 자바로 짠 메뉴를 쓰다보니까.... 이거저것 머리가 돌을정도로......^.^
너무 잡담이 길어서 죄송합니다...
제 경험도 쪼금만 참조하세요.
array_fill 은 다음 링크 참조.
http://man.phpschool.com/manual/en/function.array-fill.php

(PHP 4 >= 4.2.0, PHP 5)
array_fill -- Fill an array with values
Description
array array_fill ( int start_index, int num, mixed value)

array_fill() fills an array with num entries of the value of the value parameter, keys starting at the start_index parameter. Note that num must be a number greater than zero, or PHP will throw a warning.
© SIRSOFT
현재 페이지 제일 처음으로