PHP Chop() Function Returns String Minus Any Ending Whitespace And Newlines. – String Function

 
Its syntax is: string chop (string str)//Using chop() to remove unnecessary newlines:<?
    $header = "Table of Contents:\n\n";
    $header = chop($header);
    print $header;
?>

Enjoyed this post? Share it!

 

Leave a comment

Your email address will not be published.