Support » Fixing WordPress » pr function developed by Mahamad Khalid

  • Tarsem Singh

    (@tarsemsingh)


    Just create a function in your theme functions.php like..

    <?php
     pr($array)
      {
        echo "<pre>";
         print_r($array);
        echo "</pre>";
      }
    ?>

    Now you can use this function any where in your theme or Plugins.. to see php array e.g. for wp_query, user info etc.

    How to use:

    <?php
    pr($array);
    ?>
  • The topic ‘pr function developed by Mahamad Khalid’ is closed to new replies.