그누보드 설치2에서 오류 메시지 질문 ㅠ 채택완료
그누보드4 설치중입니다
오류 메시지 해결방안좀 부탁드립니다 ㅠㅠ
인스톨시 밑에 같은 메시지가 뜨는데
Warning: Use of undefined constant mysql_host - assumed 'mysql_host' (this will throw an Error in a future version of PHP) in /home/boomfile/html/install/install_db.php on line 25
Warning: Use of undefined constant mysql_user - assumed 'mysql_user' (this will throw an Error in a future version of PHP) in /home/boomfile/html/install/install_db.php on line 26
Warning: Use of undefined constant mysql_pass - assumed 'mysql_pass' (this will throw an Error in a future version of PHP) in /home/boomfile/html/install/install_db.php on line 27
Warning: Use of undefined constant mysql_db - assumed 'mysql_db' (this will throw an Error in a future version of PHP) in /home/boomfile/html/install/install_db.php on line 28
Warning: Use of undefined constant admin_id - assumed 'admin_id' (this will throw an Error in a future version of PHP) in /home/boomfile/html/install/install_db.php on line 29
Warning: Use of undefined constant admin_pass - assumed 'admin_pass' (this will throw an Error in a future version of PHP) in /home/boomfile/html/install/install_db.php on line 30
Warning: Use of undefined constant admin_name - assumed 'admin_name' (this will throw an Error in a future version of PHP) in /home/boomfile/html/install/install_db.php on line 31
Warning: Use of undefined constant admin_email - assumed 'admin_email' (this will throw an Error in a future version of PHP) in /home/boomfile/html/install/install_db.php on line 32
Warning: Use of undefined constant charset - assumed 'charset' (this will throw an Error in a future version of PHP) in /home/boomfile/html/install/install_db.php on line 34
Fatal error: Uncaught Error: Call to undefined function mysql_query() in /home/boomfile/html/install/install_db.php:34 Stack trace: #0 {main} thrown in /home/boomfile/html/install/install_db.php on line 34
인스톨 디비 php 파일을 보면
$mysql_host = $_POST[mysql_host];
$mysql_user = $_POST[mysql_user];
$mysql_pass = $_POST[mysql_pass];
$mysql_db = $_POST[mysql_db];
$admin_id = $_POST[admin_id];
$admin_pass = $_POST[admin_pass];
$admin_name = $_POST[admin_name];
$admin_email = $_POST[admin_email];
if (strtolower($g4[charset]) == 'utf-8') @mysql_query("set names utf8");
이렇게 되어 있는데 어떻게 수정을 해줘야 되는건가요?
답변 2개
$mysql_host = $_POST['mysql_host'];
$mysql_user = $_POST['mysql_user'];
$mysql_pass = $_POST['mysql_pass'];
$mysql_db = $_POST['mysql_db'];
$admin_id = $_POST['admin_id'];
$admin_pass = $_POST['admin_pass'];
$admin_name = $_POST['admin_name'];
$admin_email = $_POST['admin_email'];
답변에 대한 댓글 4개
ex)단독 서버이면 php.ini에서 "display_errors = off"이렇게 수정하면 그대로 사용 할수도 있다고 합니다.
댓글을 작성하려면 로그인이 필요합니다.
해당오류는 php버전올라가면서 배열안에있는 문자열을 ''으로 감싸줘야합니다
아니면 상수나 숫자로 인식을해버리니깐요
흠.. 그누4면 옛버전이라 이런곳이 많을껀데.. 그누5로 진행하시는게 좋을것같아요
저런곳이 한두군대가 아닐것같아서 배열에 [mysql_host]이런식으로 되어있는 것들은 모두다 ['mysql_host']이런방식으로 바꿔주셔야합니다
답변에 대한 댓글 6개
Warning: Use of undefined constant charset - assumed 'charset' (this will throw an Error in a future version of PHP) in /home/boomfile/html/install/install_db.php on line 34
Fatal error: Uncaught Error: Call to undefined function mysql_query() in /home/boomfile/html/install/install_db.php:34 Stack trace: #0 {main} thrown in /home/boomfile/html/install/install_db.php on line 34
이 메시지는 뭔가요? ㅠㅠ
이걸 그누5로 바꿀수가 있는건가요?
그누4로 제작된거면 어쩔수없죠
댓글을 작성하려면 로그인이 필요합니다.
답변을 작성하려면 로그인이 필요합니다.
로그인
Warning: Use of undefined constant charset - assumed 'charset' (this will throw an Error in a future version of PHP) in /home/boomfile/html/install/install_db.php on line 34
Fatal error: Uncaught Error: Call to undefined function mysql_query() in /home/boomfile/html/install/install_db.php:34 Stack trace: #0 {main} thrown in /home/boomfile/html/install/install_db.php on line 34
이 메시지는 뭔가요? ㅠㅠ