Author: latz

  • Botany Bay: Old Men with Ballpoint Pens

    Botany Bay haben ein nettes Musikvideo zum Thema Überwachung gemacht:

    Old Men With Ballpoint Pens

    They know it is the worst thing
    Not being in control
    So they bring in all the big guns
    To ease their troubled souls
    You can see them in the tabloids
    Where they smile their empty smiles
    Selling tales of lawless chaos
    And lies upon lies
    They waste no time, they’re on the way
    They’re quick to bend the laws
    To abuse the ones who suffered
    For their twisted cause

    Old men with ballpoint pens
    Old men with ballpoint pens
    Old men with ballpoint pens
    Old men with ballpoint pens

    They know what you’ve been doing
    They know where you have been
    They read the words, both yours and mine
    They’ve seen what you have seen
    They’re here to protect you
    All for the common good
    Don’t you dare to get in their way
    They just know what’s good for you
    And if you’re feeling watched
    And if you’re full of fear
    Remember that, remember how
    It was you who brought them here

    Old men with ballpoint pens…

    Botany Bay erklären per Musikvideo ihre Unterstützung für die Piratenpartei

  • pagebar v2.55

    • Fixed: function name collision with YARPP.
    • Fixed: $_POST parameter collision with FireStat.
    • Added: contextual help

    Download:

  • Surf Radio

    The summer is coming to an end but there’s a solution to keep the spirit alive:
    Surf Radio!

    Update (23JUL10): Unfortunately this radio station went away.

  • WordPress: pagebar 2.54

    pagebar 2.54 removes a problem with the “Break comments into pages” setting which could not be deselected. Unfortunately I had to remove the “show all comments” feature since I have not found a different method to code this feature.

    Additionally there are two more fixes:

    • Settings where not correctly inherited by multipagebar and commentbar.
    • Commentbar was displayed if only one page was present.

    Download:

    Hope I didn’t break anything else 😉

  • The Inner Chapters Part I

    The Inner Chapters journal my own quest to improve in the craft of programming. Each chapter reflects on a specific practice or principle through the lens of my own experiences both as a professional and an enthusiast. The name refers to the Chinese classic of philosophy, the Chuang Tzu. Divided into two sections, the Inner Chapters make up the first part attributed to the philosopher Chuang Tzu himself. The commentaries on the first section, written by his students and others, are known as the Outer Chapters. I hope you will contribute to my Outer Chapters by sharing your own thoughts and experiences on growing as a programmer.

    The Inner Chapters Audio-Promo :
    [audio:http://elektroelch.de/pics/Inner_Chapters_Promo.mp3|bg=0xCDDFF3|leftbg=0x357DCE|lefticon=0xF2F2F2|rightbg=0xF06A51|rightbghover=0xAF2910|
    righticon=0xF2F2F2|righticonhover=0xFFFFFF|text=0x357DCE|slider=0x357DCE|track=0xFFFFFF|
    border=0xFFFFFF|loader=0xAF2910]

    Links:

  • Hello Dolly 2010

    Since 2 weeks there’s a voting on Digging into WordPress whether to keep the Hello Dolly plugin in the standard distribution or to chuck it out the house.

    One of the most heard reasons for the existence of Hello Dolly that it should be used as a pattern for novice plugin developers. In my mind the problem with this argumentation is that the plugin hasn’t changed essentially since WordPress v1.21 (the version which introduced plugins in May 2004).

    Since then the environment for plugins has changed a lot. The main difference is that there are typically ten or more plugins installed on a blog. Therefore it’s mor important than ever that the plugins don’t interfere with each other. This can most easily be achieved by encapsulation and this leads inevitable to object-oriented programming. Here’s my attempt to take Hello Dolly to the next decade:

    < ?php
    /**
     * @package Hello_Dolly
     * @author Matt Mullenweg
     * @version 1.5.1
     */
    /*
    Plugin Name: Hello Dolly
    Plugin URI: http://wordpress.org/#
    Description: This is not just a plugin, it symbolizes the hope and enthusiasm of an entire generation summed up in two words sung most famously by Louis Armstrong: Hello, Dolly. When activated you will randomly see a lyric from Hello, Dolly in the upper right of your admin screen on every page.
    Author: Matt Mullenweg
    Version: 1.5.1
    Author URI: http://ma.tt/
    */
    
    if (! class_exists('Hello Dolly')) {
    	class HelloDolly { 
    
    		function hello_dolly_get_lyric() {
    			/** These are the lyrics to Hello Dolly */
    			$lyrics = "Hello, Dolly
    			Well, hello, Dolly
                            [...]
    			It's so nice to have you back where you belong
    			You're lookin' swell, Dolly
    
    			Dolly'll never go away
    			Dolly'll never go away again";
    
    			// Here we split it into lines
    			$lyrics = explode("n", $lyrics);
    
    			// And then randomly choose a line
    			return wptexturize( $lyrics[ mt_rand(0, count($lyrics) - 1) ] );
    		}
    
    		// This just echoes the chosen line, we'll position it later
    		function hello_dolly() {
    			$chosen = $this->hello_dolly_get_lyric();
    			echo "

    $chosen

    "; } // We need some CSS to position the paragraph function dolly_css() { // This makes sure that the posinioning is also good for right-to-left languages $x = ( 'rtl' == get_bloginfo( 'text_direction' ) ) ? 'left' : 'right'; echo " #dolly { position: absolute; top: 4.5em; margin: 0; padding: 0; $x: 215px; font-size: 11px; } "; } //dolly_css() } //class }//if class_exists() $HelloDolly = new HelloDolly; if (isset($HelloDolly)) { add_action('admin_head', array(&$HelloDolly, 'dolly_css')); // Now we set that function up to execute when the admin_footer action is called add_action('admin_footer', array(&$HelloDolly, 'hello_dolly')); } ?>

    As you can see all the code is encapsuled in the HelloDolly class and the only variable names visible to the rest of the system are class HelloDolly and $HelloDolly. It’s not very likely that there will be another plugin using the variables.
    This may not be too important in this small plugin but it gives the user a good and up-to-date prototype for more complex code. Maybe this code will convince the 76% that this new Dolly is a cow that is not only sacred but also meaty.

  • WordPress: Überschriften mit Untertiteln

    In vielen Zeitungen ist es üblich, unter die eigentliche Überschrift noch einen Untertitel zu setzen, um den folgenden Titel näher zu erläutern:

    Durch diese Untertitel kann man den eigentlichen Titel etwas kreativer gestalten und anschließend erläutern. Leider bietet WordPress von Haus aus diese Funktion nicht an und so muss sie nachgerüstet werden. Als ersten Reflex würde der geneigte Programmierer eine Lösung per Plugin versuchen, allerdings gibt s auch eine Lösungmit Bordmitteln. Die Zauberworte lauten “Benutzerdefinierte Felder” (engl. “custom fields”).

    (more…)

  • xnation.fm

    Nachdem Michael Jackson gestern das Zeitliche gesegnet hat werden uns die etablierten Radiosender wohl Wochen oder vielmehr Monate mit Titel wie “Billie Jean”. “Bad” oder “Dirty Diana” zumüllen. Solange man allerdings an einem Rechner mit Internetanschluss und Soundkarte sitzt kann man diesem Terror entkommen.
    Mein augenblicklicher Zufluchtsort nennt xnation.fm. Hier die letzten fünf Lieder die gerade gespielt wurden:

    Hört sich nach einer guten Alternative an!

    Sehr schön ist auch die begleitende Webseite, die sich nicht auf bunte blinkende Bilder beschränkt, sondern eine Liveticker mit den zuletzt gespielten Liedern inklusive Links auf die Bio der Band und die Texte des aktuellen Liedes anbietet. Vorbildlich.

  • Die Tim und Holgi Show

    Tim Pritlove und Holger Klein im vollkommen ungeplanten Podcast: Not Safe for Work 001. Erinnert ein wenig an die alten Spreeblick-Podcasts.