Date:2 February 2007 I Comments: 0 I Views:4,384

If you look hard enough you can fiind anything online! Even elusive snippets of code to customise your wordpress admin area.

I’m building a site using lots of templates so I’ve got more editing control locally so I wanted to list my templates dropdown list in the wordpress admin area in alphabetical order.

I searched wordpress.org and only found one unanswered post on the subject.

I dug a littel deeper and found this page:

http://trac.wordpress.org/attachment/ticket/2926/2926.diff

It reveals a snippet of code:

ksort($templates);

You have to insert it in the admin_functions.php file in the wp_admin folder near the page_template_dropdown function.

I’ve done it and it works a treat! Sorts those templates!

 

Category: Blogging