php-windows Digest 2 Aug 2003 04:18:29 -0000 Issue 1849
Topics (messages 20976 through 20984):
IMAP extension active but does not seem to try to go out to the mail host
20976 by: Brad
SNMP seems to time out returns
20977 by: Brad
Re: Failure remote includes
20978 by: m.r.
20979 by: Sek-Mun Wong
20981 by: m.r.
20983 by: Sek-Mun Wong
20984 by: m.r.
Re: Apache or IIS
20980 by: Jon Phipps
20982 by: Sek-Mun Wong
Administrivia:
To subscribe to the digest, e-mail:
[EMAIL PROTECTED]
To unsubscribe from the digest, e-mail:
[EMAIL PROTECTED]
To post to the list, e-mail:
[EMAIL PROTECTED]
----------------------------------------------------------------------
--- Begin Message ---
Added the IMAP extension..
when i try to use it, it seems that it isn't even trying to get to the host
(no hang, timeout).
it responds IMMEDIATELY with the message:
Warning: imap_open(): Couldn't open stream {imap.xyssx.com:143}MAIN in
xxx.php on line 76
of course the subsequent calls fail as the stream isn't open so it gets an
invalid imap resource.
any clues?? seems to be partially installed and di that through an Apache
restart.. Do I need to bounce the server (that seems extreme).
thanks.
--- End Message ---
--- Begin Message ---
Windows 2K server with Apache. Added the SNMP module (now i don't get bad
function calls!).
Seems when I try to use the functions it trys to get to the router, but
doesn't return information.
Getting "no response" :
Warning: snmprealwalk(): No response from escr1e in C:\WebDoc\snmpinfo.php
on line 13
NULL
Warning: snmpget(): No response from escr1e in C:\WebDoc\snmpinfo.php on
line 15
code:
<html>
<head>
<title>
Information from PHP SMNP
</title>
</head>
<body>
<?php
$host = "eeeeee";
$community = "public";
print("<center><p>PHP information from SNMP follows:<br>\n");
$myarray == snmprealwalk($host,$community,".3.6.1.2.1.2.2.1.2");
var_dump($myarray);
print(snmpget($host,$community,".3.6.1.2.1.1.4"));
?>
</p></center></body></html>
--- End Message ---
--- Begin Message ---
No, it's not silly, it's a good question, but indeed allow_url_fopen=On,
it's On by default in PHP 4,3 installations.
However, how to fopen eand read a socket via HTTP, I guess my knowlegde
fails as how to accomplish this.
I don't *need* apache 2, I guess, and might install 1.3.28, but for now
don't want to give up too easily on this one, in case it's just a simple
configuration flaw on my part (am newbie).
Thanks very much!
_________________Original message_______________
Sek-Mun Wong wrote August 1 2003 8:19 in reply to Re: Failure remote
includes
<..silly one but i assume you already have "allow_url_fopen=On" in php.ini?
(it should tell you anyway, that this is not set, plus the error below)
works for me in 4.3.2/winxp pro/apache 1.3.28.
I guess if you don't *need* apache 2, don't do it.
another test might be to fopen and read a socket via http to make sure your
connection (or I should say apache's service logon user's connection) to the
aforementioned ip/host is ok...>
--- End Message ---
--- Begin Message ---
No problem... 2.0 gave me a lot of problems (2.0.47), not that I would run
apache2/win32/php-sapi in production for the moment.
as for fopen, if you're intent to try, then:
$fp = fopen ("http://www.example.com/", "r");
while (!feof($fp)) {
$content .= fread($fp,1024);
}
fclose ($fp);
print $content;
this is just a sanity check to see if the fopen is indeed working with
url_open, or that nothing is blocking the request. Otherwise it could be
just apache2.
"M.R." <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
No, it's not silly, it's a good question, but indeed allow_url_fopen=On,
it's On by default in PHP 4,3 installations.
However, how to fopen eand read a socket via HTTP, I guess my knowlegde
fails as how to accomplish this.
I don't *need* apache 2, I guess, and might install 1.3.28, but for now
don't want to give up too easily on this one, in case it's just a simple
configuration flaw on my part (am newbie).
Thanks very much!
_________________Original message_______________
Sek-Mun Wong wrote August 1 2003 8:19 in reply to Re: Failure remote
includes
<..silly one but i assume you already have "allow_url_fopen=On" in php.ini?
(it should tell you anyway, that this is not set, plus the error below)
works for me in 4.3.2/winxp pro/apache 1.3.28.
I guess if you don't *need* apache 2, don't do it.
another test might be to fopen and read a socket via http to make sure your
connection (or I should say apache's service logon user's connection) to the
aforementioned ip/host is ok...>
--- End Message ---
--- Begin Message ---
As a follow up on my earlier reply, I found out how to read the socket and
GET / HTTP, and that works on the remote files. However, a simple include
doesn't.
_________________Original message_______________
Sek-Mun Wong wrote August 1 2003 8:19 in reply to Re: Failure remote
includes
<..silly one but i assume you already have "allow_url_fopen=On" in php.ini?
(it should tell you anyway, that this is not set, plus the error below)
works for me in 4.3.2/winxp pro/apache 1.3.28.
I guess if you don't *need* apache 2, don't do it.
another test might be to fopen and read a socket via http to make sure your
connection (or I should say apache's service logon user's connection) to the
aforementioned ip/host is ok...>
--- End Message ---
--- Begin Message ---
M.R.,
my educated guess is that somehow the include code works differently for
php-sapi on apache2. It's not optimal, but unisntall apache2, reinstall
1.3.2x and test it out. (nuke it from orbit, it's the only way to be sure)
"M.R." <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
As a follow up on my earlier reply, I found out how to read the socket and
GET / HTTP, and that works on the remote files. However, a simple include
doesn't.
_________________Original message_______________
Sek-Mun Wong wrote August 1 2003 8:19 in reply to Re: Failure remote
includes
<..silly one but i assume you already have "allow_url_fopen=On" in php.ini?
(it should tell you anyway, that this is not set, plus the error below)
works for me in 4.3.2/winxp pro/apache 1.3.28.
I guess if you don't *need* apache 2, don't do it.
another test might be to fopen and read a socket via http to make sure your
connection (or I should say apache's service logon user's connection) to the
aforementioned ip/host is ok...>
--- End Message ---
--- Begin Message ---
Thanks yes, fopen works on all remote files, no blocking.
Guess then it's Apache version 2 making the trouble.....
------------Original Message-----------------------
Sek-Mun Wong wrote 2003-08-01 15:11:18 in reply to RE: Failure remote
includes
<just a sanity check to see if the fopen is indeed working with url_open, or
that nothing is blocking the request. >
--- End Message ---
--- Begin Message ---
What it boils down to is how comforatble are you editing the conf file
by hand. If you run multiple virtual servers on multiple domains from
one ip address then the setup in IIS is heaps easier than in apache.
However, that being said, apache does not suffer from the server worms
that IIS is suceptible to. I know there are patches and security fixes
and wot not but really how much time do you want to spend securing the
server?
Jon
--- End Message ---
--- Begin Message ---
true... I've always thought that if someone can code php or java,
configuring a conf file should be (and is) a piece of cake. It suprises me
to find many developers have a morbid fear (or maybe it's just laziness) of
configuring servers by editing a conf file. I guess the division of labour
and hyper-specialisation has limited us from thinking outside (or at least
in another area of) the box.
"Jon Phipps" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
> What it boils down to is how comforatble are you editing the conf file
> by hand. If you run multiple virtual servers on multiple domains from
> one ip address then the setup in IIS is heaps easier than in apache.
> However, that being said, apache does not suffer from the server worms
> that IIS is suceptible to. I know there are patches and security fixes
> and wot not but really how much time do you want to spend securing the
> server?
>
> Jon
>
--- End Message ---