fork(1) download
  1. <?php
  2. class SampleClass
  3. {
  4. function getValue()
  5. {
  6. return "foobar";
  7. }
  8. }
  9. $sc = new SampleClass();
  10. SampleFunction($sc);
  11.  
  12.  
  13. function SampleFunction($refClass)
  14. {
  15. echo $refClass->getValue();
  16. }
  17. ?>
Success #stdin #stdout 0.02s 13112KB
stdin
Standard input is empty
stdout
foobar