marcinex

PHP: Umlaute in HEX-Code umwandeln

Hier ist eine kleine Funktion, mit der man Umlaute in HEX-Code umwandeln kann.

PHP-code:

function strip_umlaute($wert){

	$umlaute = Array("/ä/","/ö/","/ü/","/Ä/","/Ö/","/Ü/","/ß/");
	$replace = Array("ä","ö","ü","Ä","Ö","Ü","ß");
	$wert = preg_replace($umlaute, $replace, $wert);

	return $wert;
}

Kommentar schreiben

Protected by WP-Hashcash.

PHP: Umlaute in HEX-Code umwandeln

Hier ist eine kleine Funktion, mit der man Umlaute in HEX-Code umwandeln kann.

PHP-code:

function strip_umlaute($wert){

	$umlaute = Array("/ä/","/ö/","/ü/","/Ä/","/Ö/","/Ü/","/ß/");
	$replace = Array("ä","ö","ü","Ä","Ö","Ü","ß");
	$wert = preg_replace($umlaute, $replace, $wert);

	return $wert;
}

Kommentar schreiben

Protected by WP-Hashcash.