00:00
00:00
Newgrounds Background Image Theme

Schwicky just joined the crew!

We need you on the team, too.

Support Newgrounds and get tons of perks for just $2.99!

Create a Free Account and then..

Become a Supporter!

PHP and stuff.

1,108 Views | 12 Replies
New Topic Respond to this Topic

PHP and stuff. 2001-03-31 11:48:40


I was just wondering....

How can I create scripts using PHP/CGI etc.

Im new to that kind of thing and ive already tried downloading things like PHP 4 but once unzipped, the file extention isnt recognized by my computer.

Is there something else I need to create PHP scripts?

Please tell me from the beginning (i.e. the first program i need and the kind of server i need to have.)

Thanks for all your help.

Response to PHP and stuff. 2001-03-31 12:07:31


Go read this post.

Response to PHP and stuff. 2001-03-31 12:35:35


At 3/31/01 12:07 PM, aladinsane wrote: Go read this post.

OK thanks but I still dont know if my server supports PHP, how can I find that out?

Response to PHP and stuff. 2001-03-31 13:30:58


At 3/31/01 12:35 PM, Y2Kalvo wrote:
At 3/31/01 12:07 PM, aladinsane wrote: Go read this post.
OK thanks but I still dont know if my server supports PHP, how can I find that out?

Create a test file called "phpinfo.php3". Here's the steps.

1/. Open notepad.

2/. Copy and paste the following code:

<HTML>
<HEAD>
<TITLE>PHP Information</TITLE>
</HEAD>
<BODY>

<? phpinfo(); ?>

</BODY>
</HTML>

3/. Save as phpinfo.php3
4/. Upload to your server and go to that address (http://someplace.com/phpinfo.php3)

You'll need to save it as a .php3 file rather than .php just in case your server is running version 3 of the software. V3 will not parse files with the .php extension correctly, though any variant of version 4 will, and will also parse php3 files.

If that works, you should get all the details about what version your server is running. If not, you'll probably get a "download this to disk, or open from location" message, in which case you're out of luck.

Have fun.

Response to PHP and stuff. 2001-03-31 14:34:16


At 3/31/01 01:30 PM, liljim wrote:

Create a test file called "phpinfo.php3". Here's the steps.

I opened notepad and did what you said but it saves as

phpinfo.php3.txt

I havent installed the PHP 4.0.4pl or whatever its called yet and so i think thats why it wont save as .php3

Once i install it, what do i do then? As i think i said im really new to this php stuff and from what ive seen on web sites explaining it i have no idea on how to work it.

When i go to save as on notepad would it come up with .php3 under the different extention types?

Im probably sounding really annoying here but i hope to learn php and use it in my upcoming website.

Thanks a lot for everyones help.

Response to PHP and stuff. 2001-03-31 14:46:11


At 3/31/01 02:34 PM, Y2Kalvo wrote:
At 3/31/01 01:30 PM, liljim wrote:

Create a test file called "phpinfo.php3". Here's the steps.
I opened notepad and did what you said but it saves as

phpinfo.php3.txt

I havent installed the PHP 4.0.4pl or whatever its called yet and so i think thats why it wont save as .php3

Once i install it, what do i do then? As i think i said im really new to this php stuff and from what ive seen on web sites explaining it i have no idea on how to work it.

When i go to save as on notepad would it come up with .php3 under the different extention types?

Im probably sounding really annoying here but i hope to learn php and use it in my upcoming website.

Thanks a lot for everyones help.

That's just because Notepad adds the .txt extension to everything by default. When you save the file, name it phpinfo.php3 and then make sure 'All Files (*.*)' is selected in the 'Save as Type' box in Notepad.

It has nothing to do with having PHP installed on your computer or not, as the PHP interpreter is not like a normal Windows program. Unless you're planning to build really complex applications there is little point in tryiing to run PHP on your own computer anyway, as long as your web server understands it you should be OK.

Response to PHP and stuff. 2001-03-31 14:47:41


At 3/31/01 02:34 PM, Y2Kalvo wrote:
At 3/31/01 01:30 PM, liljim wrote:

Create a test file called "phpinfo.php3". Here's the steps.
I opened notepad and did what you said but it saves as

phpinfo.php3.txt

So rename it (take off the .txt). You can read all files in Notepad, providing they aren't too large.

I havent installed the PHP 4.0.4pl or whatever its called yet and so i think thats why it wont save as .php3

Once i install it, what do i do then? As i think i said im really new to this php stuff and from what ive seen on web sites explaining it i have no idea on how to work it.

You are approaching this all wrong. DO NOT install anything on your machine. It's pointless. Installing the win32 version of PHP will just give you headaches.

All you need to write PHP files are these: notepad, Internet Browser, and a server to upload to that has PHP hosting on offer.

I see you are on f2s.com They're running PHP4. so, there's your worries over installing over. Just start reading up on how to create the files. If you upload that file I instructed you on making to your f2s.com account, it will work, I guarantee it. You can even change the file to the .php extension instead of .php3 if you like.

Let me know how you get on.

Response to PHP and stuff. 2001-03-31 15:10:03


At 3/31/01 02:47 PM, liljim wrote:

Let me know how you get on.

Well ive uploaded it to http://www.strangehillstudios.f2s.com/phpinfo.php3 but when i go there it gives me a 404 error. The f2s site will be taken down once my new site is up, as Strangehill Studios doesn't exist anymore. In the future i shall be using my own domain most likely from magic-moments.com, which if i remember correctly support php4.

Thanks for both your help.

Please try the link and see what comes up but maybe i only get that error cos it hasn't actually uploaded yet (f2s say that sometimes it wont appear straight away).

Thanks again.

Response to PHP and stuff. 2001-03-31 15:16:24


Additional points of reference:

Thickbook.com - Accompanies books by Juli Meloni. It has loads of really simple code snippets, tutorials, etc. Note that this is really simple stuff, but it'll keep you going for a good while.

PHP Resource Index - By Matt Wright (who also runs CGI Resource Index. Packed full of examples, tutorials and pre-written scripts.

Devshed - Excellent for all web-related programming languages.

PHP.net - The official PHP site. In partcularly, look at the Quick Reference area, which lists all of the in-built functions.

From Php.net, get yourself signed up on the newsgroups (through Outlook Express).

PHPBuilder.com

PHPMyAdmin - manage your MySQL database using this free tool (yes, you get a database with f2s.com too).

I think that covers it. If anyone else uses any resources I've not listed, I'm all ears.

Response to PHP and stuff. 2001-03-31 15:16:39


At 3/31/01 03:10 PM, Y2Kalvo wrote:
Well ive uploaded it to http://www.strangehillstudios.f2s.com/phpinfo.php3

Actually it turns out if you add .txt to the end of that you'll get a blank screen. i tried renaming it but no matter what it still has .php3.txt

Response to PHP and stuff. 2001-03-31 15:31:41


At 3/31/01 03:16 PM, liljim wrote:
PHP Resource Index - By Matt Wright (who also runs CGI Resource Index. Packed full of examples, tutorials and pre-written scripts.

I went to this one and downloaded a zip file containing the source files for an easy hit counter but one of them had the "Open With" icon. This was called Source.php

I couldn't open this file. How can i do it?

Response to PHP and stuff. 2001-03-31 15:35:34


At 3/31/01 03:16 PM, Y2Kalvo wrote:
At 3/31/01 03:10 PM, Y2Kalvo wrote:
Well ive uploaded it to http://www.strangehillstudios.f2s.com/phpinfo.php3
Actually it turns out if you add .txt to the end of that you'll get a blank screen. i tried renaming it but no matter what it still has .php3.txt

Check your email.

Response to PHP and stuff. 2001-03-31 15:51:23


At 3/31/01 03:35 PM, liljim wrote:
Check your email.

Check yours.