Jump to content

licensing addon - domain value empty when print_r $vars using AfterModuleCreate hook


cgheonea

Recommended Posts

Hey everyone,

 

I am using license addon which auto creates once the order is accepted.

Based on: http://docs.whmcs.com/Hooks:AfterModuleCreate

I should be able to get the values of all in article mentioned variables.

However, the domain value is empty.

 

So far I have this:

<?php

if (!defined("WHMCS")){
die("This file cannot be accessed directly");
}

function EchoVars($vars){
$product_content = print_r($vars, TRUE);
file_put_contents("/home/whmcs/logs/aftercreate.log",$product_content,FILE_APPEND);
}
add_hook('AfterModuleCreate', 10, 'EchoVars');

 

the output is:

Array

(

[params] => Array

(

[accountid] => 25

[serviceid] => 25

[userid] => 1

[domain] =>

[username] =>

[password] => 123456789

[packageid] => 1

[pid] => 1

[serverid] => 0

[status] => Active

[type] => other

[producttype] => other

[moduletype] => licensing

[configoption1] => 10

[configoption2] =>

[configoption3] => 0

[configoption4] => on

[configoption5] => on

[configoption6] => on

[configoption7] => 0|None

[configoption8] => 1234567e4fa36498479ac067ad123456

[configoption9] => 0

[configoption10] =>

[configoption11] =>

[configoption12] =>

[configoption13] =>

[configoption14] =>

[configoption15] =>

[configoption16] =>

[configoption17] =>

[configoption18] =>

[configoption19] =>

[configoption20] =>

[configoption21] =>

[configoption22] =>

[configoption23] =>

[configoption24] =>

[customfields] => Array

(

[super Admin First Name] => John

[super Admin Last Name] => Smith

[super Admin Email] => JSmith@mail.com

[super Admin Username] => jsmith

[super Admin Password] => 123456789

=>

)

 

[configoptions] => Array

(

)

 

[clientsdetails] => Array

(

[userid] => 1

[id] => 1

[uuid] => 12345678-e62f-4085-a7b4-123456789123

[firstname] => John

[lastname] => Smith

[fullname] => John Smith

[companyname] => none

=> JSMITH@mail.com

[address1] => Broadway

[address2] =>

[city] => NY

[fullstate] => N/A

[state] => N/A

[postcode] => 205202

[countrycode] => US

[country] => US

[phonenumber] => 0865210

[password] => $2y$10$RVvXgkx4zLHimobsdBkREOXQormqs8Za8EI3ijUWrR.ejS5c./Gwi

[statecode] => N/A

[countryname] => US

[phonecc] => 40

[phonenumberformatted] => +40.865210

[billingcid] => 0

[notes] =>

[twofaenabled] =>

[currency] => 1

[defaultgateway] => paypal

[cctype] =>

[cclastfour] =>

[gatewayid] =>

[securityqid] => 0

[securityqans] =>

[groupid] => 0

[status] => Active

[credit] => 0.00

[taxexempt] =>

[latefeeoveride] =>

[overideduenotices] =>

[separateinvoices] =>

[disableautocc] =>

[emailoptout] =>

[overrideautoclose] =>

[allowSingleSignOn] => 1

[language] =>

[lastlogin] => No Login Logged

)

 

[server] =>

[serverip] =>

[serverhostname] =>

[serverusername] =>

[serverpassword] =>

[serveraccesshash] =>

[serversecure] =>

[serverhttpprefix] =>

[serverport] =>

)

 

)

Link to comment
Share on other sites

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