I have a function with a big hierarchy:
function func(){
$a= 0; // Here the variable is 0
while(...){
echo $a; // gives me always 0
for(...){
if(...){
if(...){
$num = func3();
$a = $num; // this $a does not corrospond to $a in the beginning
}
}
}
}
}
Does anyone know how I can change the value of $a
from the nested scopes?