View Full Version : PHP on hard drive
benslayton
07-05-2006, 11:11 PM
Is there any way that i can view php on my computer rather than on the net?
djr33
07-05-2006, 11:35 PM
Sure. Setup your computer as a webserver.
Look at php.net for the files to install to a "server" and do so to your computer. Note that you should have apache or something installed to run it with (not sure on the specifics here, sorry).
Webservers aren't the only way to do it, though they're usually the best. If you just want to test some simple code, though, it's faster to use the command-line interpreter:
prompt$ php
<?php echo("Five plus three is " . (5+3)); ?>
(end-of-input control sequence, ctrl-D on *n?x)
Five plus three is 8
prompt$
benslayton
07-06-2006, 02:17 AM
Ok so youre saying put the php code between
"prompt$ php
//content here
prompt$
You enter the code after executing the "php" command and before pressing the control sequence :)
djr33
07-07-2006, 10:53 AM
Er... that's automatically on your system? I'm clearly missing something.
BLiZZaRD
07-07-2006, 10:58 AM
Er... that's automatically on your system? I'm clearly missing something.
I think it's somewhere near that -GR key :p
djr33
07-07-2006, 11:07 AM
I'm up way too late, and just got a really fun picture of a whole bunch of gears spinning around in Twey's head.
Hehe.
BLiZZaRD
07-07-2006, 11:46 AM
I don't know about "a whole bunch"... unless they are all loose :p
Almost certainly :p
Er... that's automatically on your system? I'm clearly missing something.It is on *n?x if you supply the correct compile options (I think building a command-line interpreter is default). On Windows I believe there's an executable, php.exe, that comes bundled with the package.
Powered by vBulletin® Version 4.2.2 Copyright © 2021 vBulletin Solutions, Inc. All rights reserved.