[development] I added a hook_menu function to my product_type custom module but when I go to "https://mydomain/cart/refreshcart " it says "The requested page could not be found."

Carl Wiedemann carl.wiedemann at gmail.com
Sun Jan 30 20:30:40 UTC 2011


Any changes to hook_menu requires cache clear.

Additionally, if you are calling uc_cart_block directly, this function
requires arguments to return the markup for the specific block delta, i.e.
$op = 'view' $delta = 0. Please see uc_cart.module -- you may simply want to
create your own callback and repurpose some of the code if you are
implementing this via AHAH.


On Sun, Jan 30, 2011 at 1:06 PM, Ken Rickard <agentrickard at gmail.com> wrote:

> Did you clear the menu cache?
>
>
>
> On Jan 30, 2011, at 2:56 PM, John Mitchell <mitchelljj98 at gmail.com> wrote:
>
> I added a hook_menu function (see below) to my product_type custom module
> but when I go to " <https://mydomain/>https://mydomain/*cart/refreshcart*
> "
> it says "The requested page could not be found.".  I have directly called
> other urls that were defined within the hook_menu function for the
> ubercart/uc_cart/uc_cart.module file and they came back fine like "<https://mydomain/admin/store/settings/cart>
> https://mydomain/admin/store/settings/cart".
>
> Any idea why this would not work?
>
> Thanks,
>
> John
>
> /**
>  * Implementation of hook_menu().
>  */
>
> function product_type_menu() {
>   $items = array();
>
>   $items['*cart/refreshcart*'] = array(
>     'title' => 'Refresh Shopping Cart',
>     'description' => 'Refresh Shopping Cart',
>     'page callback' => 'uc_cart_block',
>     'access callback' => TRUE,
>     'type' => MENU_CALLBACK,
>     'file' => 'ubercart/uc_cart/uc_cart.module',
>   );
>
>   return $items;
> }
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.drupal.org/pipermail/development/attachments/20110130/368f994c/attachment-0001.html 


More information about the development mailing list