Use variable defined outside function : Variable Scope : Language Basics PHP Source Code


PHP Source Code » Language Basics » Variable Scope »

 

Use variable defined outside function




<?php
  $ilike = "Rock";
  function music(){
      echo "I love listening to $ilike music!""n";
  }
  music();
?>
           
       



HTML code for linking to this page:

Follow Navioo On Twitter

PHP Source Code

 Navioo Language Basics
» Variable Scope