|
-
Apr 20th, 2002, 03:13 PM
#1
Thread Starter
Hyperactive Member
run php ?
is there anythign i need to run a php web server?
-
Apr 20th, 2002, 03:48 PM
#2
PowerPoster
Five things
A computer (clearly you have one of these already)
An OS (ditto)
A connection to the internet (ditto again)
A web server (Try www.apache.org)
PHP binaries (Get from www.php.net)
Install Apache, install PHP, follow configuration instructions to get them to work together. Run Apache, it should say "running PHP 4.1?".
15 minute job
-
Apr 20th, 2002, 03:52 PM
#3
Member
You'll probably want to install mySQL at some time too (a db engine: a lot of boards and other scripts use it). http://www.mysql.com/, but beware it's a living hell to install for the first time.
-
Apr 20th, 2002, 04:03 PM
#4
PowerPoster
Originally posted by filburt1
but beware it's a living hell to install for the first time.
??
under windows it's a piece of cake. Just use the winmysqladmin utilty (mysql root/bin) to create a my.cnf, and run the same again.
-
Apr 20th, 2002, 04:06 PM
#5
PowerPoster
mysql was the easiest thing for me to install
USAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSA
USAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSA
USAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSA
USAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSA
USAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSA
USAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSA
USAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSA
USAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSA
USAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSA
USAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSA
USAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSA
USAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSA
USAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSA
-
Apr 20th, 2002, 04:42 PM
#6
Fanatic Member
Originally posted by chrisjk
??
under windows it's a piece of cake. Just use the winmysqladmin utilty (mysql root/bin) to create a my.cnf, and run the same again.
took me 5 minutes to install mysql
Visit www.fragblast.com
Gaming, forums, and a online RPG/Battle system
(__Flagg) DOT NET? is this a Hindi Dating service?
-
Apr 20th, 2002, 04:47 PM
#7
Thread Starter
Hyperactive Member
thanks, is there anything i need to know. like how to get to my page?
-
Apr 20th, 2002, 05:09 PM
#8
PowerPoster
when Apache installation asks for domainname, type 127.0.0.1
Then when you want to view php pages, open IE and type 127.0.0.1. You will get a dir listing on the stuff in apache root/htdocs
-
Apr 20th, 2002, 05:13 PM
#9
Thread Starter
Hyperactive Member
how could i make my own domainname?
-
Apr 20th, 2002, 05:15 PM
#10
PowerPoster
if you want it accessible to people from outside like a normal webserver, you'll have to register a domain name in the usual manner and type it in the box asking for it.
The 127.0.0.1 is for localhost testing
-
Apr 20th, 2002, 05:37 PM
#11
Member
Well thanks for making me feel bad , because I didn't want to install it to the default directory it made things really hard, so I just gave up and installed it to c:\mysql. Then I hunted around for half an hour until I was able to find out how to install it as a service, then everything was fine and dandy.
-
Apr 20th, 2002, 05:39 PM
#12
Member
Originally posted by chrisjk
if you want it accessible to people from outside like a normal webserver, you'll have to register a domain name in the usual manner and type it in the box asking for it.
The 127.0.0.1 is for localhost testing
You can fake it using http://www.dns2go.com/ . For example turtletips.dns2go.com always resolves to my computer's IP. I have it set to send a heartbeat every 20 minutes, so if my IP changes due to DHCP, turtletips.dns2go.com will point to the new one.
Or you can spend $8.95 at http://www.godaddy.com/ and get your own real domain name.
-
Apr 20th, 2002, 05:42 PM
#13
Thread Starter
Hyperactive Member
im haveing problems installing the apache thing i really need help on that now
-
Apr 20th, 2002, 06:00 PM
#14
Thread Starter
Hyperactive Member
i dont know what command line its talking about
-
Apr 20th, 2002, 06:27 PM
#15
Fanatic Member
Originally posted by filburt1
Well thanks for making me feel bad , because I didn't want to install it to the default directory it made things really hard, so I just gave up and installed it to c:\mysql. Then I hunted around for half an hour until I was able to find out how to install it as a service, then everything was fine and dandy.
i didnt install it in c:\mysql and still took me 5 min 
command line meaning the dos box that comes up. what are you trying to do?
Visit www.fragblast.com
Gaming, forums, and a online RPG/Battle system
(__Flagg) DOT NET? is this a Hindi Dating service?
-
Apr 20th, 2002, 06:43 PM
#16
-
Apr 20th, 2002, 06:45 PM
#17
Thread Starter
Hyperactive Member
is it saying command prompt? if it is i tryed that it didnt work. it said it didnt know that command im trying to install the apache thing
-
Apr 20th, 2002, 07:18 PM
#18
PowerPoster
You seem to have got lost a bit methinks.
What have you done so far?
-
Apr 20th, 2002, 07:20 PM
#19
Thread Starter
Hyperactive Member
i extracted all the apache files and i edited to conf file (kinda) but i dont know what to do after that mabey i did it wrong to begin with
-
Apr 20th, 2002, 07:24 PM
#20
PowerPoster
did you put this in httpd.conf?
LoadModule php4_module G:/php/sapi/php4apache.dll
#AddModule mod_php4.c
AddType application/x-httpd-php .php .php3
after following the instructions for PHP (i.e. installing it and copying the relevant files to the correct places)
-
Apr 20th, 2002, 07:27 PM
#21
Member
Also make sure you restart the Apache service...in a DOS console type:
Code:
net stop apache
net start apache
You might also want to just type (in the Apache dir)
And it will tell you if any of the conf files have errors.
-
Apr 20th, 2002, 07:31 PM
#22
PowerPoster
the easiest thing to do is forget consoles completely and have a shortcut pointing to apache.exe. You can then just minimise it
-
Apr 20th, 2002, 07:34 PM
#23
Member
Originally posted by chrisjk
the easiest thing to do is forget consoles completely and have a shortcut pointing to apache.exe. You can then just minimise it
Ah, but then it won't run for all users on NT-based OSes
-
Apr 20th, 2002, 07:35 PM
#24
PowerPoster
?
like windows 2000, like i have you mean
-
Apr 20th, 2002, 07:50 PM
#25
Thread Starter
Hyperactive Member
i have xp but it didnt come wiht an exe for the http thing thats what im working on so that i can get to the php part
-
Apr 20th, 2002, 07:56 PM
#26
PowerPoster
did you get the source of binary distribution; because you definately want the Win32 binary distro.
-
Apr 20th, 2002, 08:06 PM
#27
Thread Starter
Hyperactive Member
where would it be ill look, do you have any instant message program that would probly be a lot easyer than posting
-
Apr 20th, 2002, 11:20 PM
#28
Originally posted by filburt1
Ah, but then it won't run for all users on NT-based OSes
why would you want it to run for anybody else as it will be a test machine anyway.
-
Apr 21st, 2002, 12:01 AM
#29
Thread Starter
Hyperactive Member
i thought i had to have that.... i didnt know i just wanted to make it for my house. it would be a php MySQL thing can you tell me what i need then?
-
Apr 21st, 2002, 01:15 AM
#30
Thread Starter
Hyperactive Member
ok i got it installed but now i have no idea where the index files are that make my page
-
Apr 21st, 2002, 10:32 AM
#31
Thread Starter
Hyperactive Member
ok everything is installed but when i try to load a php file it shows it as text not as the web style
-
Apr 21st, 2002, 10:42 AM
#32
PowerPoster
are you using IE and have you told apache to interpret all php extensions as a php file, like this
Code:
LoadModule php4_module G:/php/sapi/php4apache.dll
#AddModule mod_php4.c
AddType application/x-httpd-php .php .php3
in httpd.conf
-
Apr 21st, 2002, 11:14 AM
#33
Thread Starter
Hyperactive Member
does it matter where i put it, because i just put it in and its still not working
-
Apr 21st, 2002, 11:18 AM
#34
PowerPoster
It shouldn't matter, i put it at the end on mine
Did you follow these instructions
Installing PHP on Windows with Apache 1.3.x
There are two ways to set up PHP to work with Apache 1.3.x
on Windows. One is to use the CGI binary (php.exe),
the other is to use the Apache module dll. In either case
you need to stop the Apache server, and edit your
srm.conf or httpd.conf to configure Apache to work with PHP.
Although there can be a few variations of configuring PHP
under Apache, these are simple enough to be used by the
newcomer. Please consult the Apache Docs for further
configuration directives.
Now that version 4.1 introduces a safer sapi module, we recommend
that you configure PHP as a module in Apache.
To do this, you should move php4ts.dll to the windows/system (for Windows 9x/Me)
or winnt/system32 (for Windows NT/2000/XP) directory, overwriting any
older file. Then you should add the following three lines to your Apache
conf file: (swap c:/php/ for your PHP install path)
LoadModule php4_module c:/php/sapi/php4apache.dll
AddModule mod_php4.c
AddType application/x-httpd-php .php
If you wish to install PHP as a CGI binary, (the sapi is much better)
you need to enable the apache security fix in your php.ini by
setting cgi.force_redirect = 1. Then, insert these lines to your conf file:
ScriptAlias /php/ "c:/php/"
AddType application/x-httpd-php .php
Action application/x-httpd-php "/php/php.exe"
As a further precaution, we recommend you change the "/php/"
ScriptAlias to something more random, to prevent any attempts to
call your binary (like the Code Red scripts) for returning a response
other than 404.
Remember when you have finished to restart the server, for example,
NET STOP APACHE
followed by
NET START APACHE
To use the source code highlighting feature, add the following
line to your apache httpd.conf file:
AddType application/x-httpd-php-source .phps
Note, this will only work when you install php as a sapi module.
If you wish to use this feature with the cgi binary, create a new
file, and use the show_source("path/to/original_file.php"); function.
On Win-Apache all backslashes in a path statement such
as: "c:\directory\file.ext", must be converted to
forward slashes.
-
Apr 21st, 2002, 03:01 PM
#35
Thread Starter
Hyperactive Member
i did but its still messing up
-
Apr 22nd, 2002, 06:46 PM
#36
Thread Starter
Hyperactive Member
ok i read it over again and its still lot loading php scripts right
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|