I would like to order alphabetically the content in my Drupal back-end
Is there any simpler method than using Views module or hacking the code for doing it ?
I don't need an ordering selector, 开发者_如何学Cjust to statically order the nodes differently.
thanks
Doing this is very simple with Views.
- Install Views module.
- Go to
/admin/build/views/list
. - Click "enable" next to whatever default node list you want to override (probably "admin_content").
- Find the "Sort criteria" section of the edit page:
- Remove "Node: updated date".
- Click the add button, choose "Node: title", "ascending".
- Save, and you're done!
- View is the simplest/easiest solution.
- An alternative solution would be to use a jQuery plugin and do sorting via js, but that would only work for the items on the page and not globally.
- You could also create your own display using
hook_menu
in a custom module. - Yet another solution would be to rewrite the SQL of
node_admin_nodes
function to implement a sorting that way, or usehook_form_alter
and create your own implementation ofnode_admin_nodes
. But that would be the most time consuming and complex route to take that I don't want to describe how you would do it in details and I would definitely adwise strongly against it. But it's a possibility if you really don't want to use views…
The core content view 'Edit' is annoyingly unconfigurable. You will need Views.
精彩评论