Sprache wechseln
wpseek auf Twitter


Eine auf WordPress spezialiserte Suchmaschine für Entwickler und Theme-Autoren




deslash [ ]

deslash ( $content )
Parameter:
  • (string) $content
Gibt zurück:
  • (string)
Definiert in:
Codex



{@internal Missing Short Description}}

{@internal Missing Long Description}}

Quellcode

function deslash($content) {
	// Note: \\\ inside a regex denotes a single backslash.

	// Replace one or more backslashes followed by a single quote with
	// a single quote.
	$content = preg_replace("/\\\+'/", "'", $content);

	// Replace one or more backslashes followed by a double quote with
	// a double quote.
	$content = preg_replace('/\\\+"/', '"', $content);

	// Replace one or more backslashes with one backslash.
	$content = preg_replace("/\\\+/", "\\", $content);

	return $content;
}

Beispiele [ wp-snippets.com ]

Top Google Suchergebnisse

Mehr ...

Nutzerduskussionen [ wordpress.org ]

0 Nutzerkommentare

Noch keine. Sei der Erste!

Neu hinzufügen ...