RE: [PHP] global array

2012-06-15 Thread ma...@behnke.biz
m: ma...@behnke.biz [mailto:ma...@behnke.biz] > > Sent: Thursday, June 14, 2012 8:04 AM > > To: php-general@lists.php.net; j...@allredmetal.com > > Subject: Re: [PHP] global array > > > > > > > > > > Jeff Burcher hat am 14. Juni 2012 um 13:55 > > g

Re: [PHP] global array

2012-06-14 Thread Jim Giner
See - I didn't even notice he used camel-case - I thought he typed the same thing that got the OP in trouble. See how difficult that custom is? That's why for any case sensitive syntax, I stick to all lower case to avoid just that kind of bug-a-boo. -- PHP General Mailing List (http://www

Re: [PHP] global array

2012-06-14 Thread Ashley Sheridan
On Thu, 2012-06-14 at 15:13 -0400, Jim Giner wrote: > "Al" wrote in message > news:6b.c0.39100.4ef1a...@pb1.pair.com... > > > > > > On 6/14/2012 12:49 PM, Jim Giner wrote: > >> Yes - PHP is very picky. Hence I never capitalize anything! I use > >> underscores to make varnames more understandab

Re: [PHP] global array

2012-06-14 Thread Jim Giner
"Al" wrote in message news:6b.c0.39100.4ef1a...@pb1.pair.com... > > > On 6/14/2012 12:49 PM, Jim Giner wrote: >> Yes - PHP is very picky. Hence I never capitalize anything! I use >> underscores to make varnames more understandable, as in $inv_req >> >> > > There is another nice custom e.g. $in

Re: [PHP] global array

2012-06-14 Thread Al
On 6/14/2012 12:49 PM, Jim Giner wrote: Yes - PHP is very picky. Hence I never capitalize anything! I use underscores to make varnames more understandable, as in $inv_req There is another nice custom e.g. $invReg it's easy to read and it doesn't conflict with PHP syntax for some function

Re: [PHP] global array

2012-06-14 Thread Jim Giner
Yes - PHP is very picky. Hence I never capitalize anything! I use underscores to make varnames more understandable, as in $inv_req -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

RE: [PHP] global array

2012-06-14 Thread Jeff Burcher
4 AM > To: php-general@lists.php.net; j...@allredmetal.com > Subject: Re: [PHP] global array > > > > > Jeff Burcher hat am 14. Juni 2012 um 13:55 > geschrieben: > > > > > function Part_BOM($PartID, $need, $phase) { > > > > > > > >

Re: [PHP] global array

2012-06-14 Thread ma...@behnke.biz
Jeff Burcher hat am 14. Juni 2012 um 13:55 geschrieben: > > function Part_BOM($PartID, $need, $phase) { > > > > global $Invreq; uppercase R !!! And much better is adding it as another parameter and inject it: function Part_BOM($PartID, $need, $phase, $InvReq) { } // c

[PHP] global array

2012-06-14 Thread Jeff Burcher
Hi, I am running PHP 5.4 on IIs 6 on a Windows SBS 2003 server. Here is a streamlined version of the code I am dealing with. I tried to trim as much as possible to only show code that deals with my issue. The main issue I think I am having is the global array statement within the function is no

Re: [PHP] global array, can't assign values from variables

2003-09-05 Thread Curt Zirzow
* Thus wrote Chris Edwards ([EMAIL PROTECTED]): > Hi > > I'm just going to give the code and output. It should be self explanatory. > The array, $criteria, is having the issue. I don't know what it's doing. I > cannot seem to assign the value from the $data variable to the > $criteria[index] va

Re: [PHP] global array, can't assign values from variables SOLVED

2003-09-05 Thread Chris Edwards
[EMAIL PROTECTED] http://www.OuterBanksInternet.com - Original Message - From: "John W. Holmes" <[EMAIL PROTECTED]> To: "Chris Edwards" <[EMAIL PROTECTED]> Cc: <[EMAIL PROTECTED]> Sent: Friday, September 05, 2003 4:11 PM Subject: Re: [PHP] global array, can't ass

Re: [PHP] global array, can't assign values from variables

2003-09-05 Thread John W. Holmes
Chris Edwards wrote: I'm just going to give the code and output. It should be self explanatory. The array, $criteria, is having the issue. I don't know what it's doing. I cannot seem to assign the value from the $data variable to the $criteria[index] value. You will see some attempts to debug

[PHP] global array, can't assign values from variables

2003-09-05 Thread Chris Edwards
Hi I'm just going to give the code and output. It should be self explanatory. The array, $criteria, is having the issue. I don't know what it's doing. I cannot seem to assign the value from the $data variable to the $criteria[index] value. You will see some attempts to debug the situation whic

Re: [PHP] help with PHP global array

2002-02-07 Thread Chris Boget
> All variables in PHP are local to the scope in which it is defined. You > cannot declare a variable as global (as such). To use a global variable: This is true. But I believe that the original question was actually the other way around... Make a local variable into a global one. The way to d

Re: [PHP] help with PHP global array

2002-02-07 Thread Jason Wong
> From: Bjorn Abt [mailto:[EMAIL PROTECTED]] > Sent: Thursday, February 07, 2002 10:57 AM > To: '[EMAIL PROTECTED]' > Subject: AW: [PHP] help with PHP global array > > > > I would try: > > global $myArray[] > > Greetings Björn > > -Urs

RE: [PHP] help with PHP global array

2002-02-07 Thread Wee Chua
EMAIL PROTECTED]' Subject: AW: [PHP] help with PHP global array I would try: global $myArray[] Greetings Björn -Ursprüngliche Nachricht- Von: Wee Chua [ mailto:[EMAIL PROTECTED] <mailto:[EMAIL PROTECTED]> ] Gesendet: Donnerstag, 7. Februar 2002 16:35 An: PHP (E-mail) Be

[PHP] Re: help with PHP global array

2002-02-07 Thread Julio Nobrega Trabalhando
$array = Array('a'=>1); function scope_test() { global $array; echo $array['a']; } Works for me, PHP 4.1.1 with the new .ini file. -- Julio Nobrega. Um dia eu chego lá: http://sourceforge.net/projects/toca Ajudei? Salvei? Que tal um presentinho? http://www.submarino.com.br/wishlist

[PHP] help with PHP global array

2002-02-07 Thread Wee Chua
Hi all, How can I declare a global array? Can I do this: $global myArray[] would I find out it is an array when I use it in other places? Thanks, Wee -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php