If you can always look into making javascript work for you. In your case :
<ul id="container"></ul> <script> function creator ( $container, opts ) { $container.append("<li class=' " + opts.class + " ' ><a rel='nofollow' /></a></li>") ; var $a = $container.find(":last").find("a") ; $a.attr( "href", opts.href || "#" ) ; $a.attr("title", opts.title || "" ) ; } $(function () { var $cnt = $("#container") , url=document.URL, title=document.title; creator($cnt, { 'href': 'http://delicious.com/post?url=' + url + '&title=' + title, 'title' : 'Submit ' + title + 'to Delicious', 'class' : "delicious" } ); creator($cnt, { 'href' : 'http://twitter.com/home?status='+ title + '%20-%20' + url, 'title' : 'Submit ' + title + ' to Twitter', 'class' : "twitter" } ); // and so on for all required hyperlinks }); </script>