Hide NS and use Server IP

Post Reply
bady
Registered
Posts: 15
Joined: 28 Sep 2016, 14:05

29 Oct 2016, 21:21

Hello,

I have 2 small Questions:
  • is it posible to hide the NS Records in the Clientarea? I found the setting to hide the SOA Records but I will hide the NS Records to.
  • Is it possible to use the Server-IP for templates? I only found the option to set a static default IP for the template, but I think it would be good if we could use the Server IP

Thanks.
User avatar
Daniel
Support
Posts: 199
Joined: 02 Aug 2013, 17:50

30 Oct 2016, 17:44

Thank you for your questions le met try to answer them:
bady wrote:is it posible to hide the NS Records in the Clientarea? I found the setting to hide the SOA Records but I will hide the NS Records to.

The current branch does not have this option. However you can manipulate the client area record output by using the custom queries feature. Please see: http://www.solutedns.com/documentation/custom-queries/

You could use something like this:

Code: Select all

define("QUERY_CLIENT_RECORDS", "AND type NOT LIKE 'NS'");

bady wrote:Is it possible to use the Server-IP for templates? I only found the option to set a static default IP for the template, but I think it would be good if we could use the Server IP[/list]

If SoluteDNS can find a product dependent IP address it can use this IP when the default IP tags are used. If it isn't able to find these IP's it will use the provided default IP address as set in the template settings. In order to be able to find related products the template must be assigned to a product. Please note the default template can not be used for this purpose as it is used for domain only registrations. When a domain is ordered together with a product you can specify a custom template to be used instead of the default one. Please see: http://www.solutedns.com/documentation/template/ and the "Handling" tab in the SoluteDNS admin area Settings.
bady
Registered
Posts: 15
Joined: 28 Sep 2016, 14:05

06 Nov 2016, 18:32

Hi Daniel, thanks!

I think I will buy your software - I like it. But I have one new question: When the client orders a Wehosting Package with a free domain. Solute creates the records after the order and not after the product creation. What is, when I use the Server Setting "Add to the least full server" and the product will creat on an other Server of the Servergroup? Is it possible that WHMCS creates the Hosting Package at first, Solute loads the product IP and create the records and whmcs registrer the domain then?
User avatar
Daniel
Support
Posts: 199
Joined: 02 Aug 2013, 17:50

07 Nov 2016, 19:12

By default SoluteDNS runs after the shoppingcartcheckout hook point. You can do additional processing using the WHMCS hook system and SoluteDNS internal API.

Please see:
  • http://docs.whmcs.com/Hooks
  • http://docs.whmcs.com/Hooks:ShoppingCartCheckoutCompletePage
  • http://www.solutedns.com/documentation/internal-api/

For example if you want to do additional processing when the order completed page is shown you could add:

Code: Select all

add_hook('ShoppingCartCheckoutCompletePage', 1, function ($vars) 
{
    ## Get IP based on  your own requirements
    $ip;  // Requires additional code

    ## Get domain related to product
    $domain = "example.com"; // Requires additional code

    ## Initiate SoluteDNS API
    $dns_api = new SDNS_api();

    $newrecord = array(
      "name" => $domain,
      "type" => "A",
      "content" => $ip,
      "prio" => "0",
      "ttl" => "3600",
    );

    ## Add new record
    $result = $dns_api->record->add($domain, $newrecord);

});
Stender
Registered
Posts: 1
Joined: 13 Sep 2018, 11:03

20 Sep 2018, 13:43

Hi Daniel, how much additional processing could you add like that? Is there a limit?
User avatar
Daniel
Support
Posts: 199
Joined: 02 Aug 2013, 17:50

22 Sep 2018, 11:40

You can add as many WHMCS hook points as you want. The information in this topic was about an older release prior to the Core being built into our WHMCS modules meaning the mentioned Internal API is no longer available. You can now use the Core API for DNS interaction: https://docs.solutedns.com/core/resources/
Post Reply