Go Premium for a chance to win a PS4. Enter to Win

x
?
Solved

New install problem.

Posted on 2002-04-14
8
Medium Priority
?
190 Views
Last Modified: 2008-02-20
I am running Windows 2000 and have installed IIS, MySQL and PHP.

I am now going thru a tutorial on PHP. The first program (the infamous 'Hello World') works, however, the second program returns an error.

The program is:

<html>
<body>
<?php
phpinfo();
?>
</body>
</html>

and the error is:

CGI Error
The specified CGI application misbehaved by not returning a complete set of HTTP headers. The headers it did return are:

I am assuming I need to do something with the install.
0
Comment
Question by:GaryZ
  • 4
  • 4
8 Comments
 
LVL 5

Expert Comment

by:andriv
ID: 6940848
Did you save it as a .php?

Are you typing the correct file name?

This is the only reasons that I can think of besides the IIS Web server not being active.
0
 

Author Comment

by:GaryZ
ID: 6941774
Yes to all. I uploaded it to a server, and it ran OK.
0
 
LVL 5

Expert Comment

by:andriv
ID: 6942131
You said it ran OK, does that mean the problem is solved.
0
Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 

Author Comment

by:GaryZ
ID: 6942254
Sorry, I meant the program ran ok when I uploaded it to my host server, but I get the error locally. Since it runs on the host server I will be using I have to assume it is coded correctly.
0
 
LVL 5

Accepted Solution

by:
andriv earned 400 total points
ID: 6942300
Does you host server require a different extension, for example .php4? If so, make sure you are using .php locally.

Also, you say the other script "hello world" did work locally, is that correct?

If yes to all of the above try:

<?
echo phpinfo();
?>

0
 

Author Comment

by:GaryZ
ID: 6942896
Got me. Just tried it again and it is working, maybe the reboot did it.

An additional question. On the host server I cannot get to the command line, so I have to create the database and add tables from script. Do you know a good site to learn this?

The tutorial I have only gives directions on how to do this from a command line.

Thanks
0
 
LVL 5

Expert Comment

by:andriv
ID: 6942923
What are you using to get the command line and what hosting company are you using.

If you want to create tables within your script you use the same mysql commands except your query will create a table:

$dbconnect = mysql_connect("host","user","password");

$mysql_select_db("dbName",$dbconnect);

$Query = "Create table tableName (prodid int(10) not null auto_increment,next field,next field)";

mysql_query($Query);
0
 

Author Comment

by:GaryZ
ID: 6942949
Thanks. I'll give that a try.

The person I am writting this for is on bright.net



0

Featured Post

Free Tool: Port Scanner

Check which ports are open to the outside world. Helps make sure that your firewall rules are working as intended.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

I imagine that there are some, like me, who require a way of getting currency exchange rates for implementation in web project from time to time, so I thought I would share a solution that I have developed for this purpose. It turns out that Yaho…
This article discusses how to implement server side field validation and display customized error messages to the client.
The viewer will learn how to count occurrences of each item in an array.
The viewer will learn how to look for a specific file type in a local or remote server directory using PHP.
Suggested Courses

877 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question