Thanks Ken,

> The issue is that you cannot actually run a database query to sort the
> menu correctly, due to the nesting of children.

Yeah, I understand from this page (http://drupal.org/node/141866) that 'We need 
to sort each subtree by weight and title in PHP' which I think is what you're 
referring to? I don't know how Views works internally - does that restriction 
of needing both a db query and some PHP post-processing make it a pain to 
implement as a view?

> You might also try http://drupal.org/project/menu_node_views

Thanks, I'll do that.

Andy

. . . . . . . 
Andy Fowlston
+44 (0)20 8747 5068
and...@pedalo.co.uk
Skype: andy.pedalo
www.pedalo.co.uk

This email is intended only for the above named addressee/s. This email may be 
confidential or legally privileged. If you have received this email and you are 
not a named addressee, you must not use, copy, distribute or disclose the email 
or any part of its contents or take any action in reliance on it. If you have 
received this email in error, please email the sender by replying to this 
message and delete it from your system. All reasonable precautions have been 
taken to ensure no viruses are present in this email. 

pedalo limited cannot accept responsibility for loss or damage arising from the 
use of this email or attachments and recommends that you subject these to your 
virus checking procedures prior to use. Any views or opinions presented are 
solely those of the author and not necessarily those of Pedalo Limited

Please consider the environment before printing this email

-----Original Message-----
From: development-boun...@drupal.org [mailto:development-boun...@drupal.org] On 
Behalf Of Ken Rickard
Sent: 04 January 2011 16:40
To: development@drupal.org
Subject: Re: [development] Sort nodes based on their position on a menu 
(views_handler_sort_menu_hierarchy?)

The issue is that you cannot actually run a database query to sort the
menu correctly, due to the nesting of children. But you can come
close. (You also can't run a clean JOIN from {node} to {menu_links}
without either a SQL calculation or a helper module.
        
You might also try http://drupal.org/project/menu_node_views, which is
the project that tries to consolidate work on Menu integration for
Views, though it could use some work.  If nothing else, you can likely
steal its sort handler.

Reply via email to