get_eol_of_text move to Common.php