cilu Posted January 21, 2012 Share Posted January 21, 2012 Hi, I would like use $params from registrant module in hook. I create hook 'ClientAdd' and I need $params["Login"], $params["Password"], $params[fullphonenumber].... How can I do it? 0 Quote Link to comment Share on other sites More sharing options...
cilu Posted January 22, 2012 Author Share Posted January 22, 2012 In domain hooks I've access to $params array $vars["params"]["Login"] but in client hooks this array is empty. Is there a function to fill array in client hooks? 0 Quote Link to comment Share on other sites More sharing options...
laszlof Posted January 22, 2012 Share Posted January 22, 2012 Each hook has different parameters passed to them based on the needs of the individual hook. If you require additional variables, you'll have to query the database for them. 0 Quote Link to comment Share on other sites More sharing options...
k1ng440 Posted January 22, 2012 Share Posted January 22, 2012 did you tried to print_r on $vars or $params? 0 Quote Link to comment Share on other sites More sharing options...
cilu Posted January 23, 2012 Author Share Posted January 23, 2012 Some $params I have from a database, as laszlof wrote, but I still need fullphonenumer. Is there any function to create fullphonenumber from phonenumber and country code? k1ng440: print_r ($params) no data print_r ($vars) no data what I look for 0 Quote Link to comment Share on other sites More sharing options...
laszlof Posted January 23, 2012 Share Posted January 23, 2012 Some $params I have from a database, as laszlof wrote, but I still need fullphonenumer. Is there any function to create fullphonenumber from phonenumber and country code? k1ng440: print_r ($params) no data print_r ($vars) no data what I look for You need to print_r/var_dump the variable being passed to your hook function. If you weren't able to figure this out, I'm afraid that the rest of this will probably confuse you. If its from a registrar module, that information is stored with the registrar. WHMCS doesn't store it at all. You can call domaingetwhois API call to get this information, but the output is going to be different based on the registrar you're using. 0 Quote Link to comment Share on other sites More sharing options...
cilu Posted January 25, 2012 Author Share Posted January 25, 2012 Ok, thank you for your response. I begin to write own functions. I've lnk to country codes /includes/countriescallingcodes.php from WHMCS support. 0 Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.