Crude link rewrite in template