httpd-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "NIPP, SCOTT V (SBCSI)" <sn4...@sbc.com>
Subject RE: Apache / PHP 4.2.1 question...
Date Wed, 15 May 2002 20:56:05 GMT
	OK.  Here is the latest.  I now have the PHP working on the first
page, to select the system name from a dropdown list.  The problem now is
that the output page is not displaying the actual requested data.  The field
names are showing up, but no data from the database.  This is very wierd.
Below is the results page PHP:

<h3 align="center">Results Of Your Query</h3>

<?php
  trim($system);
  mysql_pconnect("localhost","auto");
  mysql_select_db("LD_Systems");
  $results = mysql_query("SELECT * FROM systems WHERE Name = '$system'");
  $data = mysql_fetch_array($results);
  echo ("<font color=\h3>"."System:  ".$data["Name"]."  IP Address:
".$data["IP"]."  Primary SA:  ".$data["SA"]."<br>"."");
?> </font></body></html>

	Thanks, as usual.

-----Original Message-----
From: NIPP, SCOTT V (SBCSI)
[mailto:users-return-7203-sn4265=sbc.com@httpd.apache.org]
Sent: Wednesday, May 15, 2002 3:31 PM
To: 'users@httpd.apache.org'
Subject: RE: Apache / PHP 4.2.1 question...


	OK.  Here is the current situation...

	I now have proper output from a foo.php page on my webserver.
However, one of my database pages, currently my only page, just displays a
portion of the PHP script.  This page has a .htm extension, and works fine
on another server running Apache 1.3.24 with PHP 4.1.2.  The server I an
trying to get working is Apache 1.3.24 with PHP 4.2.1.  The working server
was setup with PHP as a static module where the broke server has PHP as a
DSO.
	Please let me know what else you may need.  I am including the PHP
code on the broken page below:

	<p align="left"><span lang="en-us">Please select system:&nbsp;
</span></p>
      
        <?php
        mysql_pconnect("localhost","auto");
        mysql_select_db("LD_Systems");
        $results = mysql_query("SELECT Name FROM systems");
        $dropdown = "<select size=\"1\" name=\"system\">\n";
          while($name = mysql_fetch_row($results)) {
            $dropdown .= "<option>$name[0]</option>\n";
          }
          $dropdown .= "</select>\n";
        ?>
      <form method="POST" action="db_query.htm">
        <?php echo "$dropdown"; ?>
        <p align="left"><input type="submit" value="Submit" name="B1"><input
type="reset" value="Reset" name="B2"></p>

	Thanks again for all the help so far.

-----Original Message-----
From: Andrew Hawkes [mailto:ahawkes@unicon.net]
Sent: Wednesday, May 15, 2002 1:50 PM
To: users@httpd.apache.org
Subject: Re: Apache / PHP 4.2.1 question...


I assume by "NOT working" you mean that you see the PHP code as text,
rather than having it interpreted. Please try to be specific about that.

There are a few post-install configuration instructions in PHP's INSTALL
file, regarding httpd.conf setup. This includes adding a "LoadModule ..."
line and a few handlers. Did you already do those things?

To test whether PHP is working at all, try creating a page (foo.php) that
contains the following:

<?php phpinfo(); ?>

and see what you get back.

-Andy


On Wed, 15 May 2002 13:39:26 -0500
"NIPP, SCOTT V (SBCSI)" <sn4265@sbc.com> wrote:

> 	OK.  How do I know if my PHP DSO module is loading or not?  The
> 	PHP portion of my page is NOT working.  Thanks in advance.
> 
> -----Original Message-----
> From: Andrew Hawkes [mailto:ahawkes@unicon.net]
> Sent: Wednesday, May 15, 2002 11:10 AM
> To: users@httpd.apache.org
> Subject: Re: Apache / PHP 4.2.1 question...
> 
> 
> Actually that's not off topic at all, in my opinion. Could you provide
> the./configure options you used?
> 
> It looks to me like apxs is complaining at the .sl extension (most Unix
> platforms have a .so extension for shared objects).
> 
> Try renaming that libphp4.sl file to libphp4.so, then (manually):
> 
> # /usr/local/apache/bin/apxs -S LIBEXECDIR="/usr/local/apache/libexec" \
> -i -a -n php4 libs/libphp4.so
> 
> That should hopefully do it. You can look in the libexec dir and see if
> php is there. If not, I'd use gcc.
> 
> -Andy
> 
> 
> On Wed, 15 May 2002 10:37:50 -0500
> "NIPP, SCOTT V (SBCSI)" <sn4265@sbc.com> wrote:
> 
> > 	I know that this might be a bit off topic, but I cannot get PHP
> > 4.2.1 to install with Apache 1.3.24.  I am attempting to build PHP as
> > per the DSO instructions.  The configure and make go fine, no errors,
> > no problems.  When I execute the 'make install' I get the following
> > error:
> > 
> > 	Making install in .
> >        		 /depot/sw/php-4.2.1/build/shtool mkdir -p
> > "/usr/local/apache/libexec" &&
> >  		/usr/local/apache/bin/apxs -S
> > LIBEXECDIR="/usr/local/apache/libexec" -i -a -n p
> > 		hp4 libs/libphp4.sl
> > 	apxs:Error: file libs/libphp4.sl is not a DSO
> > 	*** Error exit code 1
> > 
> > 	Anyone run into this before?  I am building this on HP-UX 11.00
> > 	with the standard HP C compiler.  Thanks in advance for the help,
> > 	and sorry for this being somewhat off topic.
> > Scott Nipp
> > Phone:  (214) 858-1289
> > E-mail:  sn4265@sbc.com
> > Web:  http:\\ldsa.sbcld.sbc.com
> > 
> > 
> > 
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
> > For additional commands, e-mail: users-help@httpd.apache.org
> > 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
> For additional commands, e-mail: users-help@httpd.apache.org
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
> For additional commands, e-mail: users-help@httpd.apache.org
> 

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org


Mime
View raw message