By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
437,829 Members | 2,308 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 437,829 IT Pros & Developers. It's quick & easy.

phpMyAdmin Setup

P: n/a
Okay, I've never used phpMyAdmin before but I'm trying to learn.

I've downloaded the .zip file and unzipped it on my Windows box. It
looks like all I have to do now is ftp all the files to the appropriate
directory on my RedHat box, and then just configure a few settings like
hostname, username and password.

I guess I'm not quite clear on the concept of which directory I'm
supposed to ftp the files to. Since it has to run in a web browser, I
presume I'm supposed to ftp the files to:

/var/www/html

or to a new directory I create in this location.

Yes | No?

Explain?

Jul 17 '05 #1
Share this Question
Share on Google+
7 Replies


P: n/a
> I guess I'm not quite clear on the concept of which directory I'm
supposed to ftp the files to. Since it has to run in a web browser, I
presume I'm supposed to ftp the files to:

/var/www/html

or to a new directory I create in this location.

Yes | No?


I personally upload it to its own directory within the root directory, if
you are using apache I would suggest password protecting the directory as
well otherwise anyone can come along and edit your database
Jul 17 '05 #2

P: n/a
Filth wrote:
I personally upload it to its own directory within the root directory, if
you are using apache I would suggest password protecting the directory as
well otherwise anyone can come along and edit your database


Thanks for replying.

Okay, so I guess

/myadmin

would be a plausible place to load the files, but I might still not
understand unix apache all that well. I was under the impression that,
any files which need to be viewable to a user through a browser *must*
be somewhere within /var/www/html/

IOW if I were to just enter "www.my_registered_url.org:my_httpd_port"
into a browser, when the http request hits my server, the server would
go directly to /var/www/html and look for a file called 'index.html'.

So I guess the part I'm not still clear on is how to access the
phpmyadmin files in /myadmin through a browser...

Jul 17 '05 #3

P: n/a
'bonehead <se*********@here.org> wrote in news:40**************@here.org:
So I guess the part I'm not still clear on is how to access the
phpmyadmin files in /myadmin through a browser...


www.yourdomain.com/myadmin/index.php

assuming you dont have an index.html file. And... as already posted, your
password protection that you WILL add then asks you for password. Also, try
something else other than 'myadmin', as its too easy to guess. Perhaps it
doesnt really matter, but it wont hurt to choose something more unique.

Another option, assuming you have a static IP and Apache/PHP on your home
machine, is to keep the files on your computer and see if you can get your
hosting company to allow it access to the remote database.
Jul 17 '05 #4

P: n/a
www.yourdomain.com/myadmin/index.php

assuming you dont have an index.html file. And... as already posted, your
password protection that you WILL add then asks you for password. Also, try
something else other than 'myadmin', as its too easy to guess. Perhaps it
doesnt really matter, but it wont hurt to choose something more unique.

Another option, assuming you have a static IP and Apache/PHP on your home
machine, is to keep the files on your computer and see if you can get your
hosting company to allow it access to the remote database.


I should clarify that I'm using a RedHat box at home which has apache
and php and mysql all installed on the same machine. I'm just using it
for learning purposes.

Just so I'm clear on this: Let's assume that I've registered
www.mydomain.com to a static IP which comes to my cable router at home,
and the router is configured to send incoming http requests on a
particular port to my RedHat box on my home network. If I fire up a
browser on any machine and point it to:

http://www.mydomain.com:my_port_numb...s/example1.php

when the server gets the http request, isn't the server going to look in

/var/www/html

for a directory called /bookexamples and then look in that directory for
a file called example1.php to return to the requesting host?

Doesn't this mean that if I want to create a directory to hold the
phpMyAdmin files, the directory should be located within /var/www/html
also? Wouldn't this also be true if I wanted to install, say, PHP-Nuke?

Jul 17 '05 #5

P: n/a
> Just so I'm clear on this: Let's assume that I've registered
www.mydomain.com to a static IP which comes to my cable router at home,
and the router is configured to send incoming http requests on a
particular port to my RedHat box on my home network. If I fire up a
browser on any machine and point it to:

http://www.mydomain.com:my_port_numb...s/example1.php

when the server gets the http request, isn't the server going to look in

/var/www/html

for a directory called /bookexamples and then look in that directory for
a file called example1.php to return to the requesting host?

Doesn't this mean that if I want to create a directory to hold the
phpMyAdmin files, the directory should be located within /var/www/html
also? Wouldn't this also be true if I wanted to install, say, PHP-Nuke?


Yes that is exactly the way it works. in this case /var/www/html is your
root directory, if you see instructions for uploading files etc and they
mention the root directory they will ussually mean the top level directory
that the web has access to.
Jul 17 '05 #6

P: n/a
'bonehead pathetically mumbled:
...if I want to create a directory to hold the
phpMyAdmin files, the directory should be located within /var/www/html
also? Wouldn't this also be true if I wanted to install, say, PHP-Nuke?

And Filth provided the following path to enlightenment:
Yes that is exactly the way it works. in this case /var/www/html is your
root directory, if you see instructions for uploading files etc and they
mention the root directory they will ussually mean the top level directory
that the web has access to.


Thanks for clearing that one up. I'm the type that likes to be totally
led by the nose the first time I try anything...just ask my first
girlfriend...

--
'bonehead
------------------------------------------------
Q: Where are the "Open Source" women?
You know, the ones that we can use
freely and configure to fit our needs?

A: They are all out looking for Open Source men
with a long, long list of defects and features
that need fixing...

Jul 17 '05 #7

P: n/a
>I should clarify that I'm using a RedHat box at home which has apache
and php and mysql all installed on the same machine. I'm just using it
for learning purposes.
Just be sure that your security is not so week that strangers will
be using it for anonymous child porn distribution (they CAN stick
images into a database if that's the only way to make use of their
newly-found free disk space), spamming, or remote-controlled DDOS
attacks. You don't want to find out about this when the FBI breaks
in your door.
Just so I'm clear on this: Let's assume that I've registered
www.mydomain.com to a static IP which comes to my cable router at home,
and the router is configured to send incoming http requests on a
particular port to my RedHat box on my home network. If I fire up a
browser on any machine and point it to:

http://www.mydomain.com:my_port_numb...s/example1.php

when the server gets the http request, isn't the server going to look in

/var/www/html

for a directory called /bookexamples and then look in that directory for
a file called example1.php to return to the requesting host?
True, in general, although you can use Apache directives to modify
this behavior somewhat. (See mod_alias, mod_rewrite, mod_userdir,
use of symlinks, etc.) I am assuming /var/www/html is your
DocumentRoot. The default setup varies on different systems.
Doesn't this mean that if I want to create a directory to hold the
phpMyAdmin files, the directory should be located within /var/www/html
also? Wouldn't this also be true if I wanted to install, say, PHP-Nuke?


Yes, assuming you mean the phpMyAdmin files meant to be served to
the web, NOT unprotected html files containing passwords or credit
card numbers. There are other alternatives, like giving phpMyAdmin
its own vhost, or aliasing it to somewhere else. But this is a
reasonable setup. I figure a reasonable place to put it is at
http://my.domain.com/phpMyAdmin/ (which you ARE going to password-protect,
right?)

In general, stuff for the web goes under the DocumentRoot. Stuff
NOT for the web, especially sensitive stuff like files of credit
card numbers, goes OUTSIDE the DocumentRoot. Passwords inside .php
files can be safe, but you'd better be sure that you NEVER manage
to turn PHP off (say, by breaking the plugin in the process of
upgrading to a new version).

Gordon L. Burditt
Jul 17 '05 #8

This discussion thread is closed

Replies have been disabled for this discussion.