Web Design & Development • eCommerce • Content Management • Internet Marketing • Nottingham

So I used modified versions of these snippets on a site I'm working on and they work great. One caveat though...

Since the customerror module uses some custom callbacks to execute its code, and those callbacks aren't in the menu system, breadcrumbs and navigation will possibly change on the 403 snippet. My client noticed that the although the URL was the same, all the highlighted menus and blocks went away. This one line snippet fixed all that:

<?php menu_set_active_item($_REQUEST['destination']); ?>

All it does is trick Drupal into thinking the the requested URL is the page it's on even when a different callback is really handling the request.

Posted by Michael Prasuhn on Saturday, 22 March, 2008 - 01:21.

Reply