Introducing Radical.sh

Forget Code launches a powerful code generator for building API's

PHP Function with single arguments and Multiple arguments in PHP

  1. <?php
  2. function code($a) {
  3. echo $a;
  4. echo "<br>";
  5. }
  6. code(3);
  7. code("Prasanna Vijayan");
  8. ?>
  9. // passing arguments can be integer or any datatype (String, Boolean, Float )

  1. <?php
  2. function code($a,$b) {
  3. echo $a;
  4. echo "<br>",$b;
  5. }
  6. code(3,'');
  7. code("Prasanna Vijayan",446);
  8. ?>
  9. //it is mandatory that you should pass at least null variable