Jump to content

steven99

Level 2 Member
  • Content count

    550
  • Joined

  • Last visited

  • Days Won

    13

steven99 last won the day on July 11

steven99 had the most liked content!

Community Reputation

62 Excellent

3 Followers

About steven99

  • Rank
    Level 2 Member

Recent Profile Visitors

The recent visitors block is disabled and is not being shown to other users.

  1. You can get the option within the client area with a custom addon and form on the manage credit card page that submits to the addon to toggle the setting and the addon then redirects back to the manage card page. You could also skip the addon and use a hook that watches for $_POST with specific variables and use that same form to post to clientarea.php?action=creditcard . That method may conflict with WHMCS handling of the form submission and would require testing.
  2. steven99

    question about multiple gateways

    WHMCS only attempts charges to the gateway the invoice is assigned to and wont automatically switch to another. Unfortunately there isn't a hook, at least documented, for payment failure for you to then do an action. An addon module would be needed to go through invoices and switch overdue invoices to another automated gateway. Also, if both gateways use tokens, only one can be used at a time and so switching between them for automated payments wont work.
  3. steven99

    PHP script in a .tpl file

    Yes by using the php smarty tag and enabling php tags in the configuration, however, it is not advised.
  4. steven99

    Creating a module

    To save the info, you would use the first mentioned code with the function. Below is an updated version of that function with the api to save. function carros7_CreateAccount($params) { if ($params["server"] == 1) { $Chave = md5($params['configoptions']["chave"]); $postvars = array( 'key' => $params["serveraccesshash"], 'action' => 'adicionar', 'nomeCompleto' => $params['clientsdetails']['firstname'].$params['clientsdetails']['lastname'], // Get full name {Still does not work} 'email' => $params["clientsdetails"]["email"], 'usuario' => ((isset($params["username"]) and !empty($params["username"])) ? $params["username"] : $params['clientsdetails']['firstname'].$params['clientsdetails']['lastname']), 'senha' => $params["password"], 'Chave' => $Chave, 'matrizFiliais' => $params["configoption1"], 'veiculos' => $params["configoption2"], 'funcionarios' => $params["configoption3"] ); $postdata = http_build_query($postvars); $curl = curl_init(); curl_setopt($curl, CURLOPT_URL, 'https://' . $params["serverhostname"] . 'whmcs/criar.php'); curl_setopt($curl, CURLOPT_RETURNTRANSFER,true); curl_setopt($curl, CURLOPT_SSL_VERIFYPEER, false); curl_setopt($curl, CURLOPT_SSL_VERIFYHOST, false); curl_setopt($curl, CURLOPT_POST, true); curl_setopt($curl, CURLOPT_POSTFIELDS, $postdata); $answer = curl_exec($curl); logModuleCall('carroswhmcs','CreateAccount_UserAccount','https://' . $params["serverhostname"] . 'whmcs/criar.php?'.$postdata,$answer); if (strpos($answer,"OK")!==false) { $result='success'; $CustomFields = base64_encode( serialize( array('Chave' => $Chave ) ); $AccountIDadd = localAPI('updateclientproduct', array("username"=>$params["username"],'serviceid'=>$params['serviceid'],'customfields' => $CustomFields)); if ($AccountIDadd) return $result; } else { $result=json_decode($answer,true); $result=$result['msj']; } return $result; } return "unknown error"; }
  5. steven99

    Creating a module

    function carros7_CreateAccount($params) { if ($params["server"] == 1) { $postvars = array( 'key' => $params["serveraccesshash"], 'action' => 'adicionar', 'nomeCompleto' => $params['clientsdetails']['firstname'].$params['clientsdetails']['lastname'], // Get full name {Still does not work} 'email' => $params["clientsdetails"]["email"], 'usuario' => (isset($params["username"]) and !empty($params["username"]) ? $params["username"] : $params['clientsdetails']['firstname'].$params['clientsdetails']['lastname']), 'senha' => $params["password"], 'Chave' => md5($params['configoptions']["chave"]), 'matrizFiliais' => $params["configoption1"], 'veiculos' => $params["configoption2"], 'funcionarios' => $params["configoption3"] ); $postdata = http_build_query($postvars); $curl = curl_init(); curl_setopt($curl, CURLOPT_URL, 'https://' . $params["serverhostname"] . 'whmcs/criar.php'); curl_setopt($curl, CURLOPT_RETURNTRANSFER,true); curl_setopt($curl, CURLOPT_SSL_VERIFYPEER, false); curl_setopt($curl, CURLOPT_SSL_VERIFYHOST, false); curl_setopt($curl, CURLOPT_POST, true); curl_setopt($curl, CURLOPT_POSTFIELDS, $postdata); $answer = curl_exec($curl); logModuleCall('carroswhmcs','CreateAccount_UserAccount','https://' . $params["serverhostname"] . 'whmcs/criar.php?'.$postdata,$answer); } if(strpos($answer,"OK")!==false){$result='success';}else{$result=json_decode($answer,true); $result=$result['msj'];} return $result; }
  6. steven99

    Creating a module

    You would use that within the _CreateAccount function of the provisioning module you're developing, in this case in the carros7.php file. So for example, you complete your backend processes for deploying the car to the renter and then you save the details using that code.
  7. steven99

    Creating a module

    In the provisioning module's create function, update the service details with the username you want to use. You can also use a hook to do this before the order is accepted. As for the custom field, you would save the custom field with API with for example the following. $CustomFields = base64_encode( serialize( array('CHAVE' => md5('example.') ) ); $AccountIDadd = localAPI('updateclientproduct', array("username"=>$User,"password"=>$UserPass,'serviceid'=>$params['serviceid'],'customfields' => $CustomFields)); You can also use that for the first item mentioned.
  8. Setup the ticket department to pull mail from a pop3 mailbox and have "Pipe Replies Only" disabled in the department settings. Any reply that includes the ticket number in the subject should then be routed through and added to the existing ticket.
  9. steven99

    Credits

    Correct, any credit on the account would be applied on the due date of the invoice just before it tries to charge the card. This will be indicated in the invoice as a credit line item in the balances and within the admin as "Credit card + partial credit" or "fully paid with credit" depending on which outcome the credit made.
  10. steven99

    Pages Management And Customization

    See the CMSE Content Framework module that @brian! mentioned. There are other modules that do the same thing also but some have been abandoned. WHMCS is primarily a billing and deployment system and not content management or primary site system but with modules or using custom pages it can be both. Not sure what a video would explain more than already mentioned...?
  11. steven99

    3rd Party payment gateway

    All (most) developer info is at https://developers.whmcs.com/ including API calls .
  12. steven99

    Adding a script to ticket confirmation

    You need to encase javascript with {literal} tags as smarty uses curly brackets for its use. As for the confirmation page, more information is needed on how you put it in there? via hook, template change, etc.
  13. If you are able to do manual capture via the invoice page, then you do not need the client to do anything. And if you are able to capture, then it should be automatically doing so. Check the billing menu -> gatway log for any errors during the daily batch. If it doesn't work, check your automation settings, including crons.
  14. steven99

    I want my email for all customer domains

    IIRC ICANN only requires the real data to be stored and available upon their request as well as the email address to be working. So the example above would maintain that holding of info as it would be required for the forwarding. However, it has been a while since I looked at those rules and so could require other items.
  15. steven99

    I want my email for all customer domains

    Well, that may be allowed under whois privacy rules at that is basically what those services are suppose to do.
×

Important Information

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