mikesta707 Posted August 7, 2009 Share Posted August 7, 2009 Can you pass values by reference, Ala other high level languages like C++ (and Java I think) for example, would the following compile? function afunction(&$refVar, $otherVar, $another){ //do stuff //with function //return something, also change $refVar } Quote Link to comment https://forums.phpfreaks.com/topic/169251-solved-passing-values-by-reference/ Share on other sites More sharing options...
Maq Posted August 7, 2009 Share Posted August 7, 2009 Insert Quote Can you pass values by reference, Ala other high level languages like C++ (and Java I think) Yes. Please read the manual - Passing by Reference. for example, would the following compile? Why don't you test it out? Quote Link to comment https://forums.phpfreaks.com/topic/169251-solved-passing-values-by-reference/#findComment-893105 Share on other sites More sharing options...
mikesta707 Posted August 7, 2009 Author Share Posted August 7, 2009 excellent. thank you! sorry, I don't really know why i didn't just google this... Quote Link to comment https://forums.phpfreaks.com/topic/169251-solved-passing-values-by-reference/#findComment-893111 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.