Re: Filter based on ctype_print()
| From: | Rick Emery | Date: | Mon, 05 Sep 2005 19:57:17 +0000 |
| Subject: | Re: Filter based on ctype_print() | ||
| References: | 1 2 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-221872@lists.php.net to get a copy of this message | ||
Quoting Robin Vickery <robinv@gmail.com>:
On 9/5/05, Rick Emery <rick@emery.homelinux.net> wrote:Worked great, thanks! RickWhat I really want to do is replace the non-printable character(s) with printable character(s) (maybe a question mark, or a space), but haven't been able to find a function that will do it. Maybe something like: $xmlOutput .= '<remark>'; $xmlOutput .= ctype_print_replace($remarks['Remark'], ''); $xmlOutput .= '</remark>';$xmlOutput .= preg_replace('/[^[:print:]]/', '?', $remarks['Remark']);