Page 1 of 1

Local Area Network connnection

Posted: Sat Aug 15, 2009 1:16 am
by gracepinas
Is it possible to connect a database from for example HR processor computer (serves as server) using php? how?

Is it possible to secure uploaded php codes in hr processor computer?
If possible then will it affect the user who wants the to view interface of the php? like does it need to enter password or something

Re: Local Area Network connnection

Posted: Sat Aug 15, 2009 1:19 pm
by yacahuma
i dont know what is an HR processor. But if you have unix, mac, windows, you can install PHP and apache. PHP can do almost anything.

Connect to a LAN database

Posted: Mon Aug 17, 2009 9:18 pm
by gracepinas
Is it possible to connect a mysql database that is based on a local area network?

How?

Re: Local Area Network connnection

Posted: Mon Aug 17, 2009 9:28 pm
by gracepinas
yacahuma wrote:i dont know what is an HR processor. But if you have unix, mac, windows, you can install PHP and apache. PHP can do almost anything.
I am doing an online payroll system. Instead of uploading mysql database in webhost i'll create it in the HR processor's (payroll processor) computer

Re: Connect to a LAN database

Posted: Mon Aug 17, 2009 9:40 pm
by jackpf

Code: Select all

mysql_connect('server_name:port', 'username', 'password');
Like that, I believe.

Re: Local Area Network connnection

Posted: Mon Aug 17, 2009 9:56 pm
by jackpf
What, so you want to connect to your own server from your web host's server?

You can do that. Just connect to your IP address in your script, and make sure you allow external connections to your server.

Re: Local Area Network connnection

Posted: Tue Aug 18, 2009 8:13 pm
by gracepinas
for example my msql database and php codes are in payroll processor's computer.

if i'll open it in my computer just put in ip address of the payroll processor's computer?

ex. http://192.168.1.1/index.php

like that?

i dont need to enter computer's log in ?

Re: Local Area Network connnection

Posted: Tue Aug 18, 2009 8:33 pm
by jackpf
I thought you were trying to access mysql???

But yeah, if you've opened port 80 in your firewall, then yes, on your LAN, other people can access your files being visiting your local (or external, if you've forwarded router ports to your pc) IP address.

Re: Local Area Network connnection

Posted: Fri Aug 21, 2009 10:19 pm
by gracepinas
jackpf wrote:I thought you were trying to access mysql???

But yeah, if you've opened port 80 in your firewall, then yes, on your LAN, other people can access your files being visiting your local (or external, if you've forwarded router ports to your pc) IP address.
how to do that? how come i cannot view my officemate's php like this in my browser
can you help me?

http://192.168.3.0/AblePayrollOnline/index.php

Re: Local Area Network connnection

Posted: Sat Aug 22, 2009 6:27 am
by jackpf
What error do you get? Or is it "server not found" or something..?

And probably because he hasn't opened port 80 properly.