Fw: [PHP] Variables Case Sensitivity??

2002-09-19 Thread Kevin Stone

You could concievably use the get_defined_vars(); function to impliment a
forced-variable-case machine at the start of your script.
http://www.php.net/manual/en/function.get-defined-vars.php
-Kevin

- Original Message -
From: "Georgie Casey" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Thursday, September 19, 2002 12:18 PM
Subject: [PHP] Variables Case Sensitivity??


> is there any way to make variables NOT case sensitive??
> A partner is posting information to one of my PHP scripts and cant
gurantee
> that variables passed will be lowercase
>
>
>
> --
> 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 Case Sensitivity??

2002-09-19 Thread Robert Cummings

Georgie Casey wrote:
> 
> yea, i probably didnt make that clear
> its the variables NAMES that he can't gurantee to be lowercase
> eg
> hell pass http://www.server.com/test.php?NAME=John&IDNumber=12
> when im expecting $name and $idnumber

$lowerVars = array();
foreach( $_POST as $key => $value )
{
$lowerVars[strtolower( $key )] = &$value;
}

Voila!

HTH,
Rob.
-- 
.-.
| Robert Cummings |
:-`.
| Webdeployer - Chief PHP and Java Programmer  |
:--:
| Mail  : mailto:[EMAIL PROTECTED] |
| Phone : (613) 731-4046 x.109 |
:--:
| Website : http://www.webmotion.com   |
| Fax : (613) 260-9545 |
`--'

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




Re: [PHP] Variables Case Sensitivity??

2002-09-19 Thread Georgie Casey

yea, i probably didnt make that clear
its the variables NAMES that he can't gurantee to be lowercase
eg
hell pass http://www.server.com/test.php?NAME=John&IDNumber=12
when im expecting $name and $idnumber

sorry
"Robert Cummings" <[EMAIL PROTECTED]> wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
> Georgie Casey wrote:
> >
> > is there any way to make variables NOT case sensitive??
> > A partner is posting information to one of my PHP scripts and cant
gurantee
> > that variables passed will be lowercase
>
> Sure, whatever you use make it lower case, whataever he send,
> cook to lower case.
>
> Cheers,
> Rob.
> --
> .-.
> | Robert Cummings |
> :-`.
> | Webdeployer - Chief PHP and Java Programmer  |
> :--:
> | Mail  : mailto:[EMAIL PROTECTED] |
> | Phone : (613) 731-4046 x.109 |
> :--:
> | Website : http://www.webmotion.com   |
> | Fax : (613) 260-9545 |
> `--'



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




Re: [PHP] Variables Case Sensitivity??

2002-09-19 Thread Robert Cummings

Georgie Casey wrote:
> 
> is there any way to make variables NOT case sensitive??
> A partner is posting information to one of my PHP scripts and cant gurantee
> that variables passed will be lowercase

Sure, whatever you use make it lower case, whataever he send,
cook to lower case.

Cheers,
Rob.
-- 
.-.
| Robert Cummings |
:-`.
| Webdeployer - Chief PHP and Java Programmer  |
:--:
| Mail  : mailto:[EMAIL PROTECTED] |
| Phone : (613) 731-4046 x.109 |
:--:
| Website : http://www.webmotion.com   |
| Fax : (613) 260-9545 |
`--'

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




[PHP] Variables Case Sensitivity??

2002-09-19 Thread Georgie Casey

is there any way to make variables NOT case sensitive??
A partner is posting information to one of my PHP scripts and cant gurantee
that variables passed will be lowercase



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