How can I create a view of child nodes based on the menu relationship? Say you have the following pages in a menu tree:


Projects

Project One
Project Two
Project Three



I'm looking for a way to create a view that will be embedded in the Project (parent) page that will show a pic, title and text (summary) from the child pages.

The relationship between the parent and the children is defined in the menu tree.

I know I can use node reference, but that would mean every time someone creates a page they would have to define the menu relationship and then the node reference relationship.

Also I know that I could create another content-type but I think this is overkill as all content pages look the same.
You can do exactly this using the Menu Node API
and the Menu Node Views modules.

Create a view with your required content type, and choose a contextual filter of "Menu: Menu link ID" (this is only available with the above modules installed).

Under, "When the filter value is not available," select "Provide default value" and choose "PHP code."

The following snippet will do it, then you just expose a block from the view and you are there:

if (function_exists('menu_node_get_links')){  
   $node = node_load(intval(arg(1)));  
   if (isset($node-&gt;menu_node_links)){
      foreach($node-&gt;menu_node_links as $mlid=&gt;$data){  
         return $mlid;
      }  
   }
}