I was wondering if I need to use \"break\" in \"switch\" function when \"return\" is used.
function test($string) { switch($string) { case \'test1\':
You do not need a break, the return stops execution of the function.
(for reference: http://php.net/manual/en/function.return.php says:
If called from within a function, the return() statement immediately ends execution of the current function
)