A few people have touched on it, but no-one appears to have outright asked it. I’m trying to provide custom application of the link list in the sidebar of a template for a client. There seems to be very little customisation of the layout of the link list element. For instance, I’d like to show the title before the image and wrap the whole lot (title, image and description) in the anchor.
I’ve just started playing with the functions.php file, but can’t seem to work this one out. Anyone have a sample function I could use for this?
Cheers,
T
If you mean the bookmark list?
You call into the filter with e.g.:
Where $this-filter is your filter e.g. ‘bookmark_list’ and ‘ReplaceAll’ is the function you will write. See: http://codex.wordpress.org/Plugin_API/Filter_Reference and check the chapter “blogroll filters” for most available filters.
you can then write your function ‘ReplaceAll’ like usual e.g.
In terms of functionality inside that function you can define e.g. a regular expression:
and then reshuffle the parts with the matches e.g.:
(See: http://php.net/manual/en/function.preg-match.php for how that works)
So in that way you can make it look any way you want.