Archiv

Archiv für November, 2005

links for 2005–11–28

29. November 2005

Uncategorized

Google analytics plugin, modified

28. November 2005

Ⅰ am using the $dt‑>blog(); » Google analytics plugin here on this site, but for tracking outgoing link clicks Ⅰ have had to modify the plugin like this:


add_filter('the_content', 'ga_addonclick', 10);

function ga_addonclick($value){

    if(get_option('ga_onclick')){

        $value = preg_replace("/<a href=\"([^\"]+)\"/e",
        "'<a href=\'$1\' rel=\'nofollow\' onclick=\''.ga_parseurl('$1').'\''"   ,$value);
        }
        return $value;
}

function ga_parseurl($href){
	$onclickcode = stripslashes(get_option('ga_onclick_code'));

	$href = str_replace('http://', '', $href); 

	return str_replace('$site',$href,$onclickcode);
}


Uncategorized , , ,

links for 2005–11–27

28. November 2005

Uncategorized

links for 2005–11–26

27. November 2005

Uncategorized

grabbing a file played in a flash applet via applescript

26. November 2005

Ⅰ just hacked together a little applescript that grabs files from your temporary directory to another place, renames them according to the current applications main window’s name. Basically this sounds like nothing, but what it actually does is very useful if you like to save some of the songs playing on a flash based radio stream like pandora.com. download the file here (2.4 kB zipped file).

related:

. ..

Uncategorized ,