
<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	>
<channel>
	<title>Kommentare zu: Scriptaculous: Andere Character Encoding als UTF8 verwenden</title>
	<atom:link href="http://www.ajax-info.de/code/frameworks/scriptaculous-andere-character-encoding-als-utf8-verwenden-90/feed" rel="self" type="application/rss+xml" />
	<link>http://www.ajax-info.de/code/frameworks/scriptaculous-andere-character-encoding-als-utf8-verwenden-90</link>
	<description></description>
	<pubDate>Thu, 17 May 2012 23:47:14 +0000</pubDate>
	<generator>http://wordpress.org/?v=2.6.2</generator>
		<item>
		<title>Von: mo`</title>
		<link>http://www.ajax-info.de/code/frameworks/scriptaculous-andere-character-encoding-als-utf8-verwenden-90#comment-1431</link>
		<dc:creator>mo`</dc:creator>
		<pubDate>Thu, 22 Feb 2007 19:42:51 +0000</pubDate>
		<guid isPermaLink="false">http://www.ajax-info.de/frameworks/scriptaculous-andere-character-encoding-als-utf8-verwenden-90#comment-1431</guid>
		<description>Da dein Beispiel bei mir nicht Funktioniert hat habe ich eine andere Lösung für mich gefunden, die der ein oder andere vielleicht auch gebrauchen kann.
[code lang = "php"]
$text = 'ÜüÄäÖö'
$text = preg_replace('/[^\x09\x0A\x0D\x20-\x7F]/e', '"&#38;#".ord($0).";"', $text);
[/code]
Wenn man dann den Text  übergibt muss man nur noch unescapeHTML() aufrufen und alle Zeichen werden richtig dargestellt, z.B.

[code lang = "html4"]
var titel = document.createElement("h3");
var textVar = document.createTextNode(obj.text.unescapeHTML());
titel.appendChild(textVar);
[/code]

Gruß mo</description>
		<content:encoded><![CDATA[<p>Da dein Beispiel bei mir nicht Funktioniert hat habe ich eine andere Lösung für mich gefunden, die der ein oder andere vielleicht auch gebrauchen kann.<br />
[code lang = "php"]<br />
$text = &#8216;ÜüÄäÖö&#8217;<br />
$text = preg_replace(&#8217;/[^\x09\x0A\x0D\x20-\x7F]/e&#8217;, &#8216;&#8221;&amp;#&#8221;.ord($0).&#8221;;&#8221;&#8216;, $text);<br />
[/code]<br />
Wenn man dann den Text  übergibt muss man nur noch unescapeHTML() aufrufen und alle Zeichen werden richtig dargestellt, z.B.</p>
<p>[code lang = "html4"]<br />
var titel = document.createElement(&#8221;h3&#8243;);<br />
var textVar = document.createTextNode(obj.text.unescapeHTML());<br />
titel.appendChild(textVar);<br />
[/code]</p>
<p>Gruß mo</p>
]]></content:encoded>
	</item>
</channel>
</rss>

