RE: [PHP] Variables not passed on localhost setup

2003-10-02 Thread Angelo Zanetti
with regard to register_globals being off, what kind of security
implications are there? And what would you define as badly/poorly written
php code?

brush your teeth?? =)

-Original Message-
From: CPT John W. Holmes [mailto:[EMAIL PROTECTED]
Sent: Wednesday, October 01, 2003 7:06 PM
To: [EMAIL PROTECTED]; Gal
Subject: Re: [PHP] Variables not passed on localhost setup


From: Gal [EMAIL PROTECTED]


 Reply - this means your php is running on php defaults configuration.
 you need to copy the 'php.ini-dist' file as 'php.ini' to c:\windows.
 edit the the file 'C:\windows\php.ini'
 and change register_globals = Off to register_globals = On

(and restart your web server)

(and make sure you understand the security implications that may arise from
having globals on and poorly written code)

(and brush your teeth)

---John Holmes...

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Variables not passed on localhost setup

2003-10-02 Thread - Edwin -
Hi,

On Thu, 2 Oct 2003 09:26:37 +0200
Angelo Zanetti [EMAIL PROTECTED] wrote:

 with regard to register_globals being off, what kind of security
 implications are there? And what would you define as badly/poorly
 written php code?

Here's a (simple) example:

  http://www.php.net/manual/en/security.registerglobals.php

- E -

__
Do You Yahoo!?
Yahoo! BB is Broadband by Yahoo!
http://bb.yahoo.co.jp/

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Variables not passed on localhost setup

2003-10-01 Thread CPT John W. Holmes
From: Greg Watson [EMAIL PROTECTED]
 doesn't look as
 though variables are being passed from page to page.

Register_globals is OFF in your php.ini file, so you need to use
$_GET['testvar'] instead of $testvar.

---John Holmes...

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Variables not passed on localhost setup

2003-10-01 Thread Greg Watson
Thank you for that answer! That worked perfectly!

That leads me to another query, again, which I have searched for...

I'd like to be able to switch Register_Globals ON, but I can't find my 
php.ini file.

Running phpinfo(); tells me that my 'php.ini' file is stored in 
C:\WINDOWS, but it's not there. I've ran a file search and still can't 
find it.
The only ones that appear are 'php.ini-dist' and 'php.ini-recommended' 
which live in the installation directory. I followed a tutorial to 
install PHP, which didn't say anything about specifying whether you have 
a php.ini file or not.

Any clue as to why I don't have one, and how I should get one? I 
installed PHP v4.3.3 on Apache 1.3.

Thank you again for your time, I appreciate it.

Greg Watson

CPT John W. Holmes wrote:

From: Greg Watson [EMAIL PROTECTED]
 

doesn't look as
though variables are being passed from page to page.
   

Register_globals is OFF in your php.ini file, so you need to use
$_GET['testvar'] instead of $testvar.
---John Holmes...

 



Re: [PHP] Variables not passed on localhost setup

2003-10-01 Thread Gal
Reply - this means your php is running on php defaults configuration.
you need to copy the 'php.ini-dist' file as 'php.ini' to c:\windows.
edit the the file 'C:\windows\php.ini'
and change register_globals = Off to register_globals = On
Greg Watson wrote:
Thank you for that answer! That worked perfectly!

That leads me to another query, again, which I have searched for...

I'd like to be able to switch Register_Globals ON, but I can't find my 
php.ini file.

Running phpinfo(); tells me that my 'php.ini' file is stored in 
C:\WINDOWS, but it's not there. I've ran a file search and still can't 
find it.
The only ones that appear are 'php.ini-dist' and 'php.ini-recommended' 
which live in the installation directory. I followed a tutorial to 
install PHP, which didn't say anything about specifying whether you have 
a php.ini file or not.

Any clue as to why I don't have one, and how I should get one? I 
installed PHP v4.3.3 on Apache 1.3.

Thank you again for your time, I appreciate it.

Greg Watson

CPT John W. Holmes wrote:

From: Greg Watson [EMAIL PROTECTED]
 

doesn't look as
though variables are being passed from page to page.
  


Register_globals is OFF in your php.ini file, so you need to use
$_GET['testvar'] instead of $testvar.
---John Holmes...

 


--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


Re: [PHP] Variables not passed on localhost setup

2003-10-01 Thread Ray Hunter
rename php.ini-recommended to php.ini and put it in C:\windows and you
can now use that file.

--
Ray

On Wed, 2003-10-01 at 10:52, Greg Watson wrote:
 Thank you for that answer! That worked perfectly!
 
 That leads me to another query, again, which I have searched for...
 
 I'd like to be able to switch Register_Globals ON, but I can't find my 
 php.ini file.
 
 Running phpinfo(); tells me that my 'php.ini' file is stored in 
 C:\WINDOWS, but it's not there. I've ran a file search and still can't 
 find it.
 The only ones that appear are 'php.ini-dist' and 'php.ini-recommended' 
 which live in the installation directory. I followed a tutorial to 
 install PHP, which didn't say anything about specifying whether you have 
 a php.ini file or not.
 
 Any clue as to why I don't have one, and how I should get one? I 
 installed PHP v4.3.3 on Apache 1.3.
 
 Thank you again for your time, I appreciate it.
 
 Greg Watson
 
 CPT John W. Holmes wrote:
 
 From: Greg Watson [EMAIL PROTECTED]
   
 
 doesn't look as
 though variables are being passed from page to page.
 
 
 
 Register_globals is OFF in your php.ini file, so you need to use
 $_GET['testvar'] instead of $testvar.
 
 ---John Holmes...
 
   
 

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Variables not passed on localhost setup

2003-10-01 Thread Brad Pauly
Greg Watson wrote:
I'd like to be able to switch Register_Globals ON, but I can't find my 
php.ini file.

Running phpinfo(); tells me that my 'php.ini' file is stored in 
C:\WINDOWS, but it's not there. I've ran a file search and still can't 
find it.
The only ones that appear are 'php.ini-dist' and 'php.ini-recommended' 
which live in the installation directory. I followed a tutorial to 
install PHP, which didn't say anything about specifying whether you have 
a php.ini file or not.

Any clue as to why I don't have one, and how I should get one? I 
installed PHP v4.3.3 on Apache 1.3.
Check out the Windows installation section of the manual.

http://www.php.net/manual/en/install.windows.php

Basically, you need to copy one of the ones that comes with php into 
your windows directory.

- Brad

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


Re: [PHP] Variables not passed on localhost setup

2003-10-01 Thread CPT John W. Holmes
From: Gal [EMAIL PROTECTED]


 Reply - this means your php is running on php defaults configuration.
 you need to copy the 'php.ini-dist' file as 'php.ini' to c:\windows.
 edit the the file 'C:\windows\php.ini'
 and change register_globals = Off to register_globals = On

(and restart your web server)

(and make sure you understand the security implications that may arise from
having globals on and poorly written code)

(and brush your teeth)

---John Holmes...

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Variables not passed on localhost setup [FIXED]

2003-10-01 Thread Greg Watson
Thank you all so much! That sorted it! Cheers!

I didn't see that before because I'm blind. Metorphorically speaking. 
Put it down to code-blindness from staring at the screen too long. Weird 
thing is, my searches took me to http://www.php.net/configuration, which 
didn't mention the moving ini file thing. That page told me about the 
location being a compile time option.

I'll check up on the security implications. Unfortunately for me, this 
is the way I was taught PHP. I'll have to rethink things I suppose!

I'll brush my teeth, too. Want 'em all nice and sparkly!

Thanks again, you guys are so helpful!

Greg

CPT John W. Holmes wrote:

From: Gal [EMAIL PROTECTED]

Reply - this means your php is running on php defaults configuration.
you need to copy the 'php.ini-dist' file as 'php.ini' to c:\windows.
edit the the file 'C:\windows\php.ini'
and change register_globals = Off to register_globals = On
   

(and restart your web server)

(and make sure you understand the security implications that may arise from
having globals on and poorly written code)
(and brush your teeth)

---John Holmes...

 



Re: [PHP] Variables not passed on localhost setup [FIXED]

2003-10-01 Thread Chris
On Wed, 01 Oct 2003 14:22:30 -0400, Greg Watson [EMAIL PROTECTED] 
wrote:

I'll check up on the security implications. Unfortunately for me, this
is the way I was taught PHP. I'll have to rethink things I suppose!
(and make sure you understand the security implications that may arise 
from
having globals on and poorly written code)

It would be best if you *do* get used to registered globals being off.  
It's gotten so that I can't even download premade PHP scripts anymore 
because 2 of the 3 webservers I work on have it turned off.  It's not fun 
having to sort through other people's code and making it work with 
registered globals being off (extract() is the easiest way, but I still 
have to sort through which include needs it).  It ends up being almost as 
much work as building a new one from scratch.

--
Using M2, Opera's revolutionary e-mail client: http://www.opera.com/m2/
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php