Bring the parent along to

Ok so had an issue with wanting to show the parents title in the childs seperate navigation in Drupal.

Using menu_block_split module I can achieve splitting the navigation up, but not bringing the title of the parent with it.

In the block tpl file called block-subnav.tpl.php (note: subnav is the region in my drupal template, so may be different for you.) I added a div called subtitle.

My block tpl file looks like this

</code></p>
<p>&lt;div class="subtitle"&gt;&lt;/div&gt;&lt;?php print $block-&gt;content ?&gt;</p>
<p></p>

<p>So in my jQuery I added this:<br>
<code><br>
var $linktitle = $("#nav ul.primary-links li.active-trail a").attr("title");<br>
$(".subtitle").append("&lt;h2&gt; " + $linktitle + " &lt;/h2&gt; ");

#nav ul.primary-links li.active-trail a

This is the absolute path for the html element I want, so I make that into a variable.

Then using jQuery I use the append() function and insert the title into the code.