>> Edit article
이름
제목
패스워드
: 정말 미치겠습니다. 좀 도와주세요!! : 이것 땜에 며칠째 헤메고 있습니다. : php3에서는 잘 돌아가던 디비 커넥트 소스가 왜 php4를 설치 하고 나서 : 테스트 하니까 안되는 지 모르겠군요.. : php4는 에러없이 잘 설치 했고 phpinfo();페이지를 봐도 mysql부분은 이상이 없는 것 : 같은데... : 도대체 어디가 문제 인가요?? : 다음과 같은 에러 메시지가 나타납니다. : Warning: Supplied argument is not a valid MySQL-Link resource in dbconn.inc on line 4 : ERROR CODE 0 : : 정말로 php3에서는 잘 돌아갔습니다. : 참고로 소스를 보여드릴께요.. : <? : : $dbconn = mysql_connect("localhost","사용자","비밀번호") || die("데이터베이스 연결에 실패하였습니다."); : : : : $status = mysql_select_db("GUESTBOOK",$dbconn); : : if (!$status) { : : error("DB_ERROR"); : : exit; : : } : : ?> : : 그리고 혹시 모르니php.ini의 mysql 설정 부분을 복사 해둘께요. : [MySQL] : mysql.allow_persistent=On : mysql.max_persistent=-1 : mysql.max_links = -1 : mysql.default_port = : ; mysql_connect() will use the $MYSQL_TCP_PORT, or the mysql-tcp : ; entry in /etc/services, or the compile-time defined MYSQL_PORT : ; (in that order). Win32 will only look at MYSQL_PORT. : mysql.default_socket = : ; MySQL defaults : mysql.default_host = : mysql.default_user = : mysql.default_password = : ; Note that this is generally a *bad* idea to store passwords : : 이상입니다. 제발 좀 알려주세요!! ; in this file. *Any* user with PHP access can run : ; 'echo cfg_get_var("mysql.default_password")' and reveal that : ; password! And of course, any users with read access to this : ; file will be able to reveal the password as well. 잘 돌아가는 아파치는 손도 안대셨을거구여.. php3.x 지우고 php4.0 소스컴팔하셔서 깔으셨을꺼구.. mysql은 rpm 설치하셨나요? 안되는 이유는 모르지만...mysql 을 소스컴팔하셔서 설치하시고 php4.0 ./configure --mysql= 하실때 mysql header file 디렉을 지정하시면 될껍니다. 경험상... mysql 소스로 컴팔설치시에 libmysqlclient.so ? 모 이런화일이 make install 해도 install이 안되는것 같으니까...소스푸신데에서 /usr/lib/. 으로 카피하시고...mysql client 도 카피하세요.. 잘 되는 그만이구여.. 저도 이것땜시...잘돌아가는 아파치부터...mysql ..php (APM?) 홀라당 소스설치했답니다.. 성공하시기를 ....--@~@
Copyleft
1999-2026 by
JSBoard Open Project
Theme Designed by
IDOO
All right reserved