Jump to content

Action hooks conflicting


shaynem

Recommended Posts

I've created a WHMCS module however i'm having problems with Action hooks conflicting with other modules.

 

For example, on the specific product linked to the server module there are Custom fields setup

 

we then run

 

add_hook("ShoppingCartValidateProductUpdate",1,"hook_modulename_validateuser");

 

to validate the user - but this hook also runs when there are other products with custom fields even tho the server module isn't linked to the other product

 

how can i not make this hook global and only specific to products that are linked to the server module.

 

I could not find any information in regards to this on the forums or in the documentation unless it's something obvious i've missed, however I would think that specific hooks in a /servers/modulename/hooks.php would only run on products configured for that specific module selected within the product. This seems not the case.

 

any help would be appreciated.

Link to comment
Share on other sites

  • 1 year later...

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use & Guidelines and understand your posts will initially be pre-moderated