Jquery IE .html() Error

Ein einfacher html code, der per ajax verändert werden soll.

<div><img src="icons/reddotadd.gif" title="Add Page" id="AddPageTrigger" alt="Add Page" style="border:0; cursor:pointer;" /></div>
$("#AddPageTrigger").text("TEXT hier");

schlägt im IE fehl. Warum? Keine Ahnung, aber was funktioniert ist

$("#AddPageTrigger").parent().text("TEXT hier");

Ajax Undzeichen ( &) übertragen

Normalerweise gibt es ein Problem beim Übertragen von Daten per AJAX, wenn sich ein & Zeichen in dem zuübertragenden Text / Daten befindet. Das Javascript interpretiert das Undzeichen als Trennzeichen. Alles nach dem & Zeichen wird nicht mehr übertragen. Abhilfe schafft hier die funktion encodeURIComponent

 

var save_data = 'save_text=' + encodeURIComponent($(".edit_textarea").val());
		logging(save_data);
		//return false;
		$.ajax({
			type: 'POST',
			url: 'ajax.php',
			data: save_data,
			success: function (msg){
				console.log('OK: ' + msg);
			},
			error:function (xhr, ajaxOptions, thrownError){
				alert(xhr.status);
				alert(thrownError);
			}
		});

Jetzt kommen die Daten auch an.

mod_fcgid is crashing apache windows and linux

With apache 2.3.15 I had kinda  the same issue with mod_fcgidon ubuntu 8.04 as on windows.  With -k restart or -k graceful the server did not die like on windows, but the server delivered than only a 200 OK response header, but nothing more. Switching from worker mpm to event mpm seemed to solve this, but the server died later :-/

Since it has talmost the same issues like on windows I could make a patch that fixes this. Grab the patch (patched against trunk) for the patch for 2.3.6

The bug 50309 is now longer than a year listet. Bad that none applied it yet.

Licht blockiert Fernbedienung

Ich war bei meinen Eltern zu Besuch. Dort sollte ich mir mal den receiver angucken, weil der manchmal nicht ging, bzw das Umschalten. Baterien ausgetauscht.Nicht besser. HDMI Kabel getauscht, auch keine Veränderung. Anderen Receiver geholt, keine Veränderung. Wohnzimmer nicht ausgeschaltet, siehe da: es ging. O_o

Am Ende stellte sich erhaus, das die eine Engergiesparbirne von Philipps das Infrarotlicht der Fernbedienung stört, bzw manchmal sogar ganz blockt. Darauf muss man erst mal kommen.

Secure apache against CVE-2011-3389 aka Beast attack

During the summer rumours about a new attack against SSL started circulating (CVE-2011-3389).
As it turns out, the attack itself was conceived years ago, deemed impractical, but it was nevertheless fixed in TLS 1.1. The new attack technique introduced a few optimizations to make it practical.

In terms of mitigation, I expect this problem will be largely addressed on the client side, despite a potential compatibility problem that may cause some TLS sites to stop working.

With this config you can avoid that attack.

SSLProtocol all -SSLv2
SSLHonorCipherOrder On
SSLCipherSuite ECDHE-RSA-AES256-SHA384:AES256-SHA256:RC4:HIGH:!MD5:!aNULL:!EDH:!AESGCM:!SSLV2:!eNULL

#NO Longer needed cause since IE 7 this works ;) 
#SetEnvIf User-Agent ".*MSIE.*" nokeepalive ssl-unclean-shutdown

With OpenSSL 1.0.1 it must be

SSLCipherSuite ECDHE-RSA-AES128-SHA256:AES128-GCM-SHA256:RC4:HIGH:!MD5:!aNULL:!EDH

vserver ubuntu IPv6 network

Since some days there is IPv6 available for my server. But I noticed it just today. Editing /etc/network/interfaces and adding a new virtual interface didn’t work at all. The /etc/init.d/networking restart just showed errors. And ifconfig venet0 wasn’t satisfying.

What works is /etc/network/interfaces just adding the loopbback

iface lo inet6 loopback
        adress ::1
        netmask 128
        gateway fe80::1

Now the trick is to add /etc/rc.local and add this before exit 0

ip addr add 2a01:238:40ab:cd12:dead:beef:dead:beef/128 dev venet0
ip route add default via fe80::1 dev venet0

Than execute /etc/rc.local
Wonder o wonder. Ifconfig works and also ping6 ipv6.example.com

Than I had to add the new ipv6 adress to my apache config

Listen [2a01:238:40ab:cd12:dead:beef:dead:beef]:80

Don’t forget a to create a symlink from rc.local to /etc/rc2.d/S21rc2.local

Author Archive

Archives by Month: