Php

Flickr shortcode plugin for WordPress

Earlier this week I wrote about how you can add a shortcode to the functions.php to make it easier to use Creative Commons images on your blog, while always remembering to put in the correct attribution. Adding this to your theme has some drawbacks. The most important one is that you’ll have to do it all over when you change the theme, another is that you have to add the flickr api key directly into the code.

Great news in the software world

During the last week there has been a couple of great releases in the software I use every day. First out was Python 3.1. It was released June 27th and features An ordered dictionary type Various optimizations to the int type New unittest features including test skipping and new assert methods. A much faster io module Tile support for Tkinter A pure Python reference implementation of the import statement New syntax for nested with statements Next out was Mozilla Firefox 3.

Merging two lists

Lets say you have two lists, one of them containing the values [1,2,3] and the other one containing the values [4,5,6], and you want to combine these two lists into one list, like this one: [1,2,3,4,5,6]. Let’s see how this can be done in different (high level) programming (or scripting or templating) languages. Java Java has multiple list implementations, lets start with the most basic one, the builtin array.

Merkelapper

De observante der ute (og som ikke bare leser bloggen min fra rss-leseren sin) kan ha oppdaget at merkelappene på bloggpostene har fått et nytt utseende. Det begynte egentlig med at jeg så på en post jeg hadde skrevet og tenkte “Hm, de taggene der ser ikke ut som om de egentlig hører hjemme der”. Videre tenkte jeg, hva skal jeg gjøre for å få dem mer inn i det visuelle uttrykket på bloggen.

WordPress 2.7 is out

WordPress 2.7 final was announced today. I just upgraded to wordpress 2.7. It took me about 30 seconds :D, thanks to svn switch. ?View Code BASH tar -czf backup.tar.gz blog.elzapp.com mysqldump -u root -p – elblogg > backup.sql svn sw http://svn.automattic.com/wordpress/tags/2.7 There! that’s it. 😀 Now, what’s my first impressions? It looks very nice It is VERY much slower than WordPress 2.6.5, that’s atleast my first impression.

Should have guessed it

I have sort of a love/hate relationship with Python, the programming language. Coming from PHP and Java which both have excellent documentation, while lots can be said about the solutions. With Python 2.6 the documentation really has improved, but its still not really there, while the solutions are so elegant that the only reason you don’t guess how to do stuff is that it feels too simple. Today I had one of these realizations, while reading Wayne’s snippet of the day.

Upgrading WordPress to 2.5