웹마스터 팁
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
제목 | 글쓴이 | 날짜 |
---|---|---|
1900년부터 2043년까지 음력을 양력으로..... [3] | pupstar | 2001.08.14 |
양력을 음력으로... [7] | pupstar | 2001.08.14 |
mysql_fetch_row함수와 mysql_fetch_array함수의 차이점. [4] | webzzang | 2001.08.22 |
php 로 swf 맹글기 [3] | 리산 | 2001.08.30 |
남은 계정 용량 확인하는 PHP [17] | 겜올드™ | 2001.09.09 |
Imagechar() 함수에서 한문자씩쓰는거 여러글짜이어쓰는함수 | 김승태 | 2001.10.20 |
자동차세 연체가산금 계산기 | secret | 2001.04.02 |
[GD] 이미지 회전 함수 공개합니다. [7] | 노경민 | 2001.11.05 |
알렉사 순위 가져오는 스크립트;; [30] | zero | 2001.11.06 |
게시판 만들 때 스팸메일을 막을 수 있는 방법중 한개. [11] | WOWpc | 2001.11.09 |
[추천 소스] 특정일로부터 몇일 지났나 또는 몇일 남았나 알아보는 소스 ㅡ.ㅡ; [1] | 타스케 | 2001.11.15 |
컴에 phpMyAdmin 깔고 원격 Mysql 관리.(이것도 팁이 되려나?) [1] | 최형삼 | 2001.11.17 |
phpMyAdmin에서 dump 안 되시는 분들 보세요 [5] | 똥가리 | 2001.11.18 |
MySQL에서 한글 정렬 문제 [2] | 손정호 | 2001.11.21 |
[추천 소스] phpMyAdmin 다중사용자용... [5] | WOWpc | 2001.11.29 |
[추천 팁] 디망쉬식 스킨 시스템 [4] | 디망쉬 | 2001.12.11 |
파일시스템(배열)에서의 검색기능 [5] | 두기두바 | 2002.01.09 |
파일시스템에서 비밀번호 생성/수정/인증 [7] | 두기두바 | 2002.01.10 |
cron을 이용해 윈앰프 방송정보를 빠르게 분석. [9] | Romeo | 2002.01.15 |
[PHP]모르는 분이 있는듯 해서...변수관련 [2] | TheMics | 2002.01.24 |