Make Php Function Variable Global

RegisterLogin
Make Php Function Variable Global
Post Description: Make Php Function Variable Global
Tags: Make, Php, Function, Variable, Global
This Post Was Posted On Apr 25, 2009 By takemehome2 #1382
is it possible to make a php variable string be used within a function?
Web Hosting Support
#1796 1
yes it is possbile all you have to do is to make sure you use global inside the function for example

function foo{
global $string;
echo 'hello, this is the value of my variable string: '.$string;
}


hope that helps
Apr 25, 2009 Reply Report abuse
©2011 Webune Forums - Mon Dec 19, 2011 8:01 am
Powered by: Webune Forums V3