|
|
|||||||||
|
|||||||||
| |||||||||
|
|
|
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
|
|
Stop making mediocre tutorials.The best tutorials are video! Camtasia Studio makes it easy to create engaging, buzz-building screen videos at any size, in any popular format. Download the free trial!
|
|
#1
|
|||
|
|||
|
i tried to use $GLOBALS["xyz[1]" to use the global variable in a function, but the script still stores the data in local variables. why to hell?
|
|
#2
|
|||
|
|||
|
try to define the variable like this;
$GLOBAL["xyz"] = array('1','2','3'); ...for example! or global $xyz = array(...); //etc You can then access the variable in both examples using $XYZ. Kelvin <BLOCKQUOTE><font size="1" face="Verdana,Arial,Helvetica">quote:</font><HR>Originally posted by mabraham: i tried to use $GLOBALS["xyz[1]" to use the global variable in a function, but the script still stores the data in local variables. why to hell? [/quote] [This message has been edited by releasedj (edited June 21, 2000).] |
![]() |
| Viewing: Dev Shed Forums > Other > Beginner Programming > how to use gobal variables in functions? |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|
|