php-windows Digest 4 Jun 2002 06:24:35 -0000 Issue 1174

Topics (messages 14051 through 14065):

Double quotes question
        14051 by: Clay Culver
        14054 by: Michael Davey

notice:undefined variable
        14052 by: Marius Venter
        14053 by: Michael Davey
        14057 by: Dash McElroy

ddsfdsfdsf
        14055 by: Tiago Simões
        14065 by: Tomator

Re: How do I get PHP 4.1.2 to work with Apache 2.0.36 o n win32?
        14056 by: Dash McElroy
        14058 by: Stuart Dallas

phpMyAdmin error...
        14059 by: Mircea Goia
        14061 by: Webmaster

Re: htaccess and PHP in general
        14060 by: Scott Hurring

parms are ignored
        14062 by: Diego Prusky
        14063 by: Michael Davey
        14064 by: Jason Soza

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 ---
Hi,
 
            I have a script that lists the files in a directory, and
create links accordingly but if the files contain spaces then the link
won't come out correctly. I am fairly new to PHP and have no real idea
on how I can get it to make links show as <a href="link"></a> currently
it will put links like <a href=link></a> which is causing the problem.
Below is the script.
 
[script]
<?  
function directory($result) {  
     
     $handle=opendir(".");  
     while ($file = readdir($handle)) {  
     if ($file == "." || $file == "..") { } else { print "<a
href=$file>$file</a><br />\n"; } 
       
     }  
     closedir($handle);  
 
return $result;  
}  
 
 
?>
[/script]
 
            I did try going else { print "<a href="$file">$file</a><br
/>\n"; } but all I get is PHP errors doing this until the double quote
is removed, any help in this would be great.
 
Clay
--- End Message ---
--- Begin Message ---
>             I did try going else { print "<a href="$file">$file</a><br
> />\n"; } but all I get is PHP errors doing this until the double quote
> is removed, any help in this would be great.

This would work:

print "<a href=\"$file\">";

and so would:

print "<a href='$file'>";

or even:

print <<<END
<a href="$file">
END;

But you really should have checked the manual first...
http://www.php.net/print



--- End Message ---
--- Begin Message ---
I installed PHP 4.1 on NT 4 with IIS 4. My client getting many of these
error messages when he runs his html form:


Notice: Undefined variable: background in
D:\inetpub\reservationhouse\formmail.php on line 183
The form was not submitted for the following reasons:

I NEED VALID RECIPIENT EMAIL ADDRESS () TO CONTINUE
Please use your browser's back button to return to the form and try again.

User rights are set correctly and PHP's installation went smooth. I also
tested PHP and it seems OK. Anys suggestions?

Marius Venter



--- End Message ---
--- Begin Message ---
Send your source code!

"Marius Venter" <[EMAIL PROTECTED]> wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
> I installed PHP 4.1 on NT 4 with IIS 4. My client getting many of these
> error messages when he runs his html form:
>
>
> Notice: Undefined variable: background in
> D:\inetpub\reservationhouse\formmail.php on line 183
> The form was not submitted for the following reasons:
>
> I NEED VALID RECIPIENT EMAIL ADDRESS () TO CONTINUE
> Please use your browser's back button to return to the form and try again.
>
> User rights are set correctly and PHP's installation went smooth. I also
> tested PHP and it seems OK. Anys suggestions?
>
> Marius Venter
>
>
>


--- End Message ---
--- Begin Message ---
I found I was getting these because I was not putting quotes around certain
functions. For example:

$_GET[blah] will tell you that "blah" was an undefined variable. If you do
this:
$_GET['blah'] (like php.net says...silly me) it works just fine.

Other things, like date(M-D-Y) will do the same thing. Use date("M-D-Y").

If I remember correctly, the error message tells you at least what line it
is on, possibly the variable too.

Good luck tracking down your syntax mistakes!

-Dash

-----Original Message-----
From: Marius Venter [mailto:[EMAIL PROTECTED]] 
Sent: Sunday, June 02, 2002 9:53 PM
To: [EMAIL PROTECTED]
Subject: [PHP-WIN] notice:undefined variable


I installed PHP 4.1 on NT 4 with IIS 4. My client getting many of these
error messages when he runs his html form:


Notice: Undefined variable: background in
D:\inetpub\reservationhouse\formmail.php on line 183
The form was not submitted for the following reasons:

I NEED VALID RECIPIENT EMAIL ADDRESS () TO CONTINUE
Please use your browser's back button to return to the form and try again.

User rights are set correctly and PHP's installation went smooth. I also
tested PHP and it seems OK. Anys suggestions?

Marius Venter




-- 
PHP Windows Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
--- End Message ---
--- Begin Message ---
xdsfdsfsdfdsf


--- End Message ---
--- Begin Message ---
User "Tiago SimõEs" <[EMAIL PROTECTED]> wrote:
> xdsfdsfsdfdsf
>
>

Great news! I'm impressed.


--- End Message ---
--- Begin Message ---
Use 4.2.1 or newer. 4.1.2 doesn't have support for apache 2.

Use this line in httpd.conf:

  LoadModule php4_module c:/php/experimental/apache2filter.dll

Change to your path, obviously.

-Dash

-----Original Message-----
From: Dr. D. Wagner [mailto:[EMAIL PROTECTED]] 
Sent: Monday, June 03, 2002 6:13 AM
To: [EMAIL PROTECTED]
Subject: [PHP-WIN] How do I get PHP 4.1.2 to work with Apache 2.0.36 on
win32?


Howzit,

I'm having a little trouble setting up PHP 4.1.2 to run on my Win32 
Apache 2.0.36 installation.  Apache is working flawlessly ortherwise, 
but If I try and add/uncomment the "LoadModule" line for 
php4apache.dll then Apache doesn't even load, just exits.

I've tried on both Win98SE and Win2k Pro.

I've followed the instructions almost to the letter (only changing 
directory paths where necessary).  Although none of the PHP files 
mention Apache2.

I've scoured the web for clues, and searched the archives and bug 
lists.

I've been to the phpgeek website and had a look at the page the was 
referenced a fee times in the archive, but I can't find any 
differences between that config and mine (other than the paths, and 
OS's), but it still doesn't work.

I even tried CGI mode -- apache loads, but PHP hangs when I call a 
test page.

Can someone please tell me where to get the instructions for running 
PHP 4.x on Apache 2.x.

Thanks in advance -- I've been banging my head against this wall all 
weekend, and I desperatly want to drop IIS and ASP before any more 
security holes turn up...

Dameon.

-- 
><> ><> ><> ><> ><> ><> ><> ooOOoo <>< <>< <>< <>< <>< <>< <><
Dr. Dameon Wagner
Network Administrator
Zoology Department,
University of Port Elizabeth,
South Africa.
Phone +27 41 504 2335
Fax +27 41 504 2317
E-mail: [EMAIL PROTECTED]
><> ><> ><> ><> ><> ><> ><> ><> ooOOoo <>< <>< <>< <>< <>< <><



-- 
PHP Windows Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
--- End Message ---
--- Begin Message ---
On Monday, June 3, 2002 at 2:13:03 PM, you wrote:
> I'm having a little trouble setting up PHP 4.1.2 to run on my Win32
> Apache 2.0.36 installation.  Apache is working flawlessly ortherwise, 
> but If I try and add/uncomment the "LoadModule" line for 
> php4apache.dll then Apache doesn't even load, just exits.

PHP 4.1.2 doesn't support Apache 2. You need to get PHP 4.2.x - it has a module
specifically for Apache 2.

-- 
Stuart

--- End Message ---
--- Begin Message ---
Hi,

I have a problem withg the subject.
I get first page (index.php) running correctly (I can see the left menu
which shows me the databases and the right page which shows the Welcome
message).

But when I'm trying to go to another page (let's say I want to switch to
a specific database from my server) I get this error (CGI error):
~~~~~~~~
CGI Error
The specified CGI application misbehaved by not returning a complete set
of HTTP headers. The headers it did return are:
~~~~~~~

 What could be the problem?
I'm running PHP 4.1.1. on Windows 98 with Apache 1.3.24. as web server
(with MySQL .3.23.47).

The same phpMyAdmin worked correctly on Personal Web Server as web
server (with the same Windows, PHP and MySQL .3.23.47).

Thanks,
Mircea



--
Mircea Goia
Web Developer and web design team coordinator
http://www.deep.ro (DEEP Foundation)
http://www.jiuvalley.com (Jiu Valley regional web portal)
----------------
Mircea Goia
Dezvoltator web si coordonator echipa web design
http://www.deep.ro (Fundatia DEEP)
http://www.valeajiului.ro (portalul regional al Vaii Jiului)


--- End Message ---
--- Begin Message ---
You can try to download the newest version, 4.2.0.
Returning headers usually means that there are too many spaces (blank lines)
at the php page...


"Mircea Goia" <[EMAIL PROTECTED]> schreef in bericht
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
> Hi,
>
> I have a problem withg the subject.
> I get first page (index.php) running correctly (I can see the left menu
> which shows me the databases and the right page which shows the Welcome
> message).
>
> But when I'm trying to go to another page (let's say I want to switch to
> a specific database from my server) I get this error (CGI error):
> ~~~~~~~~
> CGI Error
> The specified CGI application misbehaved by not returning a complete set
> of HTTP headers. The headers it did return are:
> ~~~~~~~
>
>  What could be the problem?
> I'm running PHP 4.1.1. on Windows 98 with Apache 1.3.24. as web server
> (with MySQL .3.23.47).
>
> The same phpMyAdmin worked correctly on Personal Web Server as web
> server (with the same Windows, PHP and MySQL .3.23.47).
>
> Thanks,
> Mircea
>
>
>
> --
> Mircea Goia
> Web Developer and web design team coordinator
> http://www.deep.ro (DEEP Foundation)
> http://www.jiuvalley.com (Jiu Valley regional web portal)
> ----------------
> Mircea Goia
> Dezvoltator web si coordonator echipa web design
> http://www.deep.ro (Fundatia DEEP)
> http://www.valeajiului.ro (portalul regional al Vaii Jiului)
>
>


--- End Message ---
--- Begin Message ---
It was just the simplest/easiest/fastest way to get what
i needed to do, done.

All that was needed was support for name/password, 
nothing else... and apache's .htpasswd is really
(IMO) ideal for such a simple user validation.

i didnt want to go to the trouble of including support for
sessions and auth and a login/logout page, etc... the
project wasn't that big -- and there was a severe time
constraint.

---
Scott Hurring
Systems Programmer
EAC Corporation
[EMAIL PROTECTED]
Voice: 201-462-2149
Fax: 201-288-1515

> -----Original Message-----
> From: Matt Babineau [mailto:[EMAIL PROTECTED]]
> Sent: Monday, June 03, 2002 3:22 PM
> To: 'Scott Hurring'
> Subject: RE: [PHP-WIN] htaccess and PHP in general
> 
> 
> Scott, you mentioned you are working on a system like this. 
> What is the
> advantage of using .htaccess/.htpasswd? I mena if the 
> authentication can
> be done using mysql and php, why should I even use .htaccess? I have a
> client that wants to avoid using any type of database, which I am
> opposed to because it makes my job very difficult. Why are 
> you using the
> htaccess in your project?
> 
> Matt Babineau
> Freelance Internet Developer
> -----------------------------------------
> e: [EMAIL PROTECTED]
> p: 603.943.4237
> w: http://www.criticalcode.com
> PO BOX 601
> Manchester, NH 03105
> 
> 
> -----Original Message-----
> From: Scott Hurring [mailto:[EMAIL PROTECTED]] 
> Sent: Friday, May 31, 2002 4:57 PM
> To: Php-Win (E-mail)
> Subject: RE: [PHP-WIN] htaccess and PHP in general
> 
> 
> Handle everything thru PHP/Mysql, but write a little function 
> that will
> read thru the Mysql database and write the .htaccess 
> files to disk as needed.
> 
> Of course, you'll have to set proper permissions on the files.
> 
> That's what i'm doing now for a project i'm working on...
> all user data is in the database, and eveyrtime a change
> is made to the DB, the .htpasswd file is written to disk
> to keep it constantly updated.  
> 
> ---
> Scott Hurring
> Systems Programmer
> EAC Corporation
> [EMAIL PROTECTED]
> Voice: 201-462-2149
> Fax: 201-288-1515
> 
> > -----Original Message-----
> > From: Matt Babineau [mailto:[EMAIL PROTECTED]]
> > Sent: Friday, May 31, 2002 10:40 AM
> > To: 'Php-Win (E-mail)'
> > Subject: [PHP-WIN] htaccess and PHP in general
> > 
> > 
> > I have a client that wants to use htaccess for verification and 
> > authentication into certain areas of a web site. I 
> suggested to use a 
> > combination of PHP/MySQL to get the jobs done. it makes my 
> life easier
> 
> > and reduces low-level administration tasks on his part letting me 
> > bundle all the administrative tasks into one neat PHP application.
> > Rather then
> > administer qmail and htaccess access via text files or 
> however they do
> > it. Does anyone have any good insight on what they think 
> > would be best?
> > I don't know alot about htaccess, so its a little foreign 
> to me. But a
> > PHP/MySQL authentication system seems as secure and far far 
> > more salable
> > to both my abilities and his needs. Any thoughts?
> >  
> > Matt Babineau
> > Freelance Internet Developer
> > -----------------------------------------
> > e:  <mailto:[EMAIL PROTECTED]> [EMAIL PROTECTED]
> > p: 603.943.4237
> > w:  <http://www.criticalcode.com/> 
> http://www.criticalcode.com PO BOX 
> > 601 Manchester, NH 03105
> >  
> > 
> 
> -- 
> PHP Windows Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
> 
--- End Message ---
--- Begin Message ---


Hello,

I recently installed PHP on W2K Server with IIS 5.0. I have the ISAPI filter
running fine, but when i send a parameter such as

http://myweb/cgi/login.php?login=rene

The value 'rene' is not showing.

The code I'm using:

<?
echo"value of var = $value";
...

Thanks

Diego

--- End Message ---
--- Begin Message ---
With the URL you have given:

> http://myweb/cgi/login.php?login=rene

Should have code looking like this...

echo"value of var = $login";

Mikey


--- End Message ---
--- Begin Message ---
Most likely your globals are turned off in php.ini.

Try this:

<?PHP

echo "Value of var = $_GET["login"]";

?>

And see if that returns the value for you.

Jason Soza

----- Original Message -----
From: "Diego Prusky" <[EMAIL PROTECTED]>
Date: Monday, June 3, 2002 4:07 pm
Subject: [PHP-WIN] parms are ignored

> 
> 
> Hello,
> 
> I recently installed PHP on W2K Server with IIS 5.0. I have the 
> ISAPI filter
> running fine, but when i send a parameter such as
> 
> http://myweb/cgi/login.php?login=rene
> 
> The value 'rene' is not showing.
> 
> The code I'm using:
> 
> <?
> echo"value of var = $value";
> ...
> 
> Thanks
> 
> Diego

--- End Message ---

Reply via email to