웹마스터 팁
page_full_width" class="col-xs-12" |cond="$__Context->page_full_width">
[추천 소스] phpMyAdmin 다중사용자용...
2001.11.29 07:49
http://mysql.netardor.net/phpMyAdmin.tar.gz이런것도 팁이 될런지 모르겠고... 또한 제가 무식하게 사용하는건지도
모르겠습니다만...
여러명이 사용하는 서버에서 각각의 사용자가 phpMyAdmin 을 사용하려고
하는 상황이다보니 다들 자기 계정에 phpMyAdmin 을 올려놓고 config.inc.php 에 자신의 DB 정보를 넣고 사용하더군요.
좀 낭비다 싶어 config.inc.php 파일을 다음과 같이 수정했습니다.
if(!isset($PHP_AUTH_USER)) {
auth();
}
else {
$id=$PHP_AUTH_USER;
$pass=$PHP_AUTH_PW;
}
$user_db = $id;
if ( $id == 'root' ) $user_db = '';
$cfgServers[1]['host'] = 'localhost'; // MySQL hostname
$cfgServers[1]['port'] = ''; // MySQL port - leave blank for default port
$cfgServers[1]['socket'] = ''; // Path to the socket - leave blank for default socket
$cfgServers[1]['connect_type'] = 'tcp'; // How to connect to MySQL server ('tcp' or 'socket')
$cfgServers[1]['adv_auth'] = false; // Use advanced authentication?
$cfgServers[1]['stduser'] = $id; // MySQL standard user (only needed with advanced auth)
$cfgServers[1]['stdpass'] = $pass; // MySQL standard password (only needed with advanced auth)
$cfgServers[1]['user'] = $id; // MySQL user (only needed with basic auth)
$cfgServers[1]['password'] = $pass; // MySQL password (only needed with basic auth)
$cfgServers[1]['only_db'] = $user_db; // If set to a db-name, only this db is accessible
// It may also be an array of db-names
이렇게 하니 자신의 apache auth 에서 자신의 DB 아이디와 비밀번호를
넣으니 자신의 DB 만 나오더군요.
root 로 로그인 했을때는 모두 다 나오게 예외처리를 하긴 했습니다만..
phpMyAdmin 2.2.0 으로 했구요.
http://mysql.netardor.net/phpMyAdmin.tar.gz
여기서 다운로드 받으실 수 있습니다...
모르겠습니다만...
여러명이 사용하는 서버에서 각각의 사용자가 phpMyAdmin 을 사용하려고
하는 상황이다보니 다들 자기 계정에 phpMyAdmin 을 올려놓고 config.inc.php 에 자신의 DB 정보를 넣고 사용하더군요.
좀 낭비다 싶어 config.inc.php 파일을 다음과 같이 수정했습니다.
if(!isset($PHP_AUTH_USER)) {
auth();
}
else {
$id=$PHP_AUTH_USER;
$pass=$PHP_AUTH_PW;
}
$user_db = $id;
if ( $id == 'root' ) $user_db = '';
$cfgServers[1]['host'] = 'localhost'; // MySQL hostname
$cfgServers[1]['port'] = ''; // MySQL port - leave blank for default port
$cfgServers[1]['socket'] = ''; // Path to the socket - leave blank for default socket
$cfgServers[1]['connect_type'] = 'tcp'; // How to connect to MySQL server ('tcp' or 'socket')
$cfgServers[1]['adv_auth'] = false; // Use advanced authentication?
$cfgServers[1]['stduser'] = $id; // MySQL standard user (only needed with advanced auth)
$cfgServers[1]['stdpass'] = $pass; // MySQL standard password (only needed with advanced auth)
$cfgServers[1]['user'] = $id; // MySQL user (only needed with basic auth)
$cfgServers[1]['password'] = $pass; // MySQL password (only needed with basic auth)
$cfgServers[1]['only_db'] = $user_db; // If set to a db-name, only this db is accessible
// It may also be an array of db-names
이렇게 하니 자신의 apache auth 에서 자신의 DB 아이디와 비밀번호를
넣으니 자신의 DB 만 나오더군요.
root 로 로그인 했을때는 모두 다 나오게 예외처리를 하긴 했습니다만..
phpMyAdmin 2.2.0 으로 했구요.
http://mysql.netardor.net/phpMyAdmin.tar.gz
여기서 다운로드 받으실 수 있습니다...
댓글 5
제목 | 글쓴이 | 날짜 |
---|---|---|
[re] 아래 행복한고니님의 할아버지 소스의 업글(?) 버젼입니다. [2] | Mahican | 2002.12.02 |
텍스트 폼에 커서가 미리 깜빡이도록... [8] | 카리 | 2003.01.22 |
로그인과 로그아웃을 체크하는 방법입니다. [3] | 이영호 | 2003.01.24 |
다음 로그인 폼 입니다... 로그인후 원하는 곳으로!! [3] | 정성교 | 2003.03.05 |
크롬리스(Chromless) 웹어플리케이션 -5 [3] | sundew | 2003.05.28 |
[초간단 자바스크립트!] 홈페이지에 FTP 폼 넣기?! [10] | ∑Ztxy | 2003.09.29 |
[초간단 자바스크립트!] 자바로 로그인폼 만들기 [3] | ∑Ztxy | 2004.01.26 |
특정위치에 떠있는 레이어 (슬라이딩 애드콘) - 노프레임홈에서의 문제해결 [8] | 검미르 | 2004.05.03 |
상위 셀렉트박스 값 변경시 하위셀렉트박스(다수)제어하기. [2] | Xian | 2005.02.19 |
{로그인}관리자 로그인 폼 간단함 [2] | 김민환 | 2006.10.10 |
쿠키(cookie)의 활용 [44] | zero | 2000.03.06 |
PHP 인증 페이지를 만들자! - Lesson 3 수정본 #1 [3] | ☺[폐]허접-_- | 2002.01.24 |
대화방을 만들어보쟈~ [20] | 해그리드짱!!! | 2001.06.03 |
[추천 소스] phpMyAdmin 다중사용자용... [5] | WOWpc | 2001.11.29 |
파일시스템에서 비밀번호 생성/수정/인증 [7] | 두기두바 | 2002.01.10 |
[OsE=] Session을 배워보자~ [#1] | OsE= | 2002.03.02 |
MYSQL에 접속하기..^^ [9] | ZipShin | 2002.05.20 |
[PHP]간단한 로그인페이지 만들기 [15] | ZipShin | 2002.07.09 |
꼭 알아야 하는 4가지 쿼리문 | Mr. JH | 2002.08.22 |
[PHP 초보에서 중수로 - 쿠키편] 1강 : 쿠키의 이해
[2]
![]() | TheMics | 2002.08.31 |