게시판 글쓰기 자동등록방지에 대해서 채택완료
스카이바디
11년 전
조회 3,756
게시판 글쓰기에 있는 자동등록방지 가
도메인 앞에 www 를 붙이면 나오지 않습니다.
그냥 www없이 도메인만으로 하면 나오고요....
http://www.samchonc.com/bbs/write.php?bo_table=customer">http://www.samchonc.com/bbs/write.php?bo_table=customer <- 여긴 안나옴
http://samchonc.com/bbs/write.php?bo_table=customer">http://samchonc.com/bbs/write.php?bo_table=customer <- 여긴 나옴
댓글을 작성하려면 로그인이 필요합니다.
답변 1개
채택된 답변
+20 포인트
11년 전
common.php 중에서
이걸루 바꿔보세요.
function g5_path()
{
$result['path'] = str_replace('\\', '/', dirname(__FILE__));
$tilde_remove = preg_replace('/^\/\~[^\/]+(.*)$/', '$1', $_SERVER['SCRIPT_NAME']);
$document_root = str_replace($tilde_remove, '', $_SERVER['SCRIPT_FILENAME']);
$root = str_replace($document_root, '', $result['path']);
$port = $_SERVER['SERVER_PORT'] != 80 ? ':'.$_SERVER['SERVER_PORT'] : '';
$http = 'http' . ((isset($_SERVER['HTTPS']) && $_SERVER['HTTPS']=='on') ? 's' : '') . '://';
$user = str_replace(str_replace($document_root, '', $_SERVER['SCRIPT_FILENAME']), '', $_SERVER['SCRIPT_NAME']);
$host = isset($_SERVER['HTTP_HOST']) ? $_SERVER['HTTP_HOST'] : $_SERVER['SERVER_NAME'];
if(isset($_SERVER['HTTP_HOST']) && preg_match('/:[0-9]+$/', $host))
$host = preg_replace('/:[0-9]+$/', '', $host);
$result['url'] = $http.$host.$port.$user.$root;
return $result;
}</p><p>
베타 버전꺼 사용하시는 것 같네요 ^^
로그인 후 평가할 수 있습니다
답변에 대한 댓글 1개
�
스카이바디
11년 전
잉끼님 감솨~~~ 넘 감솨합니다.... ^^
댓글을 작성하려면 로그인이 필요합니다.
답변을 작성하려면 로그인이 필요합니다.
로그인