Requests_IDNAEncoder::is_ascii( string $string )

Check whether a given string contains only ASCII characters


Description Description


Parameters Parameters

$string

(string) (Required)


Top ↑

Return Return

(bool) Is the string ASCII-only?


Top ↑

Source Source

File: wp-includes/Requests/IDNAEncoder.php

	protected static function is_ascii($string) {
		return (preg_match('/(?:[^\x00-\x7F])/', $string) !== 1);
	}


Top ↑

User Contributed Notes User Contributed Notes

You must log in before being able to contribute a note or feedback.