I'm trying to override the paths being set by the weather module e.g. example.com/weather/SomePlace. Reason being I already have content with URLs such as example.com/weather/tide-times

I have tried using:

function MY_MODULE_menu_alter(&$items) {
 	dsm($items);
    // Unset weather paths
    unset($items['weather']);
    unset($items['weather/autocomplete/%']);
    unset($items['weather/%/%menu_tail']);
  }

And clearing the cache, but it doesn't seem to be doing anything.

I've even tried commenting out all the $item definitions in the Weather module itself, which didn't help.
The only thing that seems to work is disabling the weather module.

Any suggestions?
Thanks

Comments

Sam Moore’s picture

Make sure your menu registry has been rebuilt. You can do drush rr from the command line.

surfgatinho’s picture

Thanks Sam,

Turns out it was a block I was including by path in Context that was showing not the actual weather module. Duh!