-------------------------------- Source: Darren's Outpost - http://ahkuan.com from entry - http://ahkuan.com/weblog/archive/2005/10/16/php-passing-by-reference.html this code fragment itself - http://ahkuan.com/weblog/20/code/1.html -------------------------------- --------------- code fragment begin --------------- // function declaration with default value function foo($bar = 'default value here'){ ... }; // function declaration with passing by reference function foo(&$bar){ ... };