Clearview Posted March 10, 2018 Share Posted March 10, 2018 Hi. I need to add some additional fields only for registering .dj domains. I have created and added the code to the additionalfields.php file as per the information at https://docs.whmcs.com/Additional_Domain_Fields However when I try to add a domain the add new order page in the Admin system, as soon as I type the dotof the domain name (before I even type the extension) it just throws the code onto the screen where I would expect the additional fields, see screen shot.. Although the documentation does not say anything, do I need to add these new fields into the database as well? Thanks Link to comment Share on other sites More sharing options...
brian! Posted March 10, 2018 Share Posted March 10, 2018 21 hours ago, Clearview said: Although the documentation does not say anything, do I need to add these new fields into the database as well? I think the documentation is missing one useful bit of info - namely because this is a PHP file, it therefore needs to start with <?php (the same as dist.additionalfields.php does)... <?php $additionaldomainfields[".dj"][] = array( "Name" => "Description of the intended use", "Type" => "text", "Size" => "250",); $additionaldomainfields[".dj"][] = array( "Name" => "1st name server", "Type" => "text", "Size" => "100",); $additionaldomainfields[".dj"][] = array( "Name" => "2nd name server", "Type" => "text", "Size" => "100",); do that, and the clients will see the above fields when ordering... 21 hours ago, Clearview said: I need to add some additional fields only for registering .dj domains. it's probably also worth mentioning that I don't think your clients will be able to order .dj domains from your website. although you can add the TLD to domain pricing (and I can see that you have), there isn't an entry for a whois server for the TLD in dist.whois.json (the default file), or in a custom whois.json file.... without that, searches for .dj domains will always respond with unavailable and the client order will not progress. if memory serves, .dj don't have a port 43 whois server, and i'm not sure the webform is one that WHMCS can handle... so unless you can find a working alternative, or use a lookup provider that sells the TLD, then clients won't be able to order them online from you. Link to comment Share on other sites More sharing options...
Clearview Posted March 10, 2018 Author Share Posted March 10, 2018 Thanks for the quick reply. I really should have noticed the missing php opening tag I am just looking to let my customers renew their names via WHMCS. I have been selling .dj domains for many years so have a proven solution for the sales. I currently have a custom written php application that deals with the renewal reminders and renewals, however since updating the servers the scheduled tasks no longer run correctly and the developer is not responding to my emails. Given that we never got all the little glitches out of the application and I already pay for WHMCS it seems to make sense to see if I can rope WHMCS into dealing with the renewal reminders and the domain renewals as well as opening up additional payment gateways for my customers (my current application only supports PayPal). I will test out the missing bit of code tomorrow. Thanks Link to comment Share on other sites More sharing options...
Clearview Posted March 10, 2018 Author Share Posted March 10, 2018 Actually just tested it now and it works perfectly thanks and the additional fields do show to me as an admin which is good as it would have been a pain to add all my existing clients info otherwise. Link to comment Share on other sites More sharing options...
brian! Posted March 11, 2018 Share Posted March 11, 2018 11 hours ago, Clearview said: Given that we never got all the little glitches out of the application and I already pay for WHMCS it seems to make sense to see if I can rope WHMCS into dealing with the renewal reminders and the domain renewals as well as opening up additional payment gateways for my customers (my current application only supports PayPal). if you're manually adding them from the admin area, then renewal handling should work fine as with any other TLD... there may be an issue with syncing the expiry date (if you use the domain sync option), but other than that, I can't see an issue for using WHMCS for this. Link to comment Share on other sites More sharing options...
Clearview Posted March 11, 2018 Author Share Posted March 11, 2018 Just tested this all today and I have come across a snag. Is there any way to make the new fields appear when the customer logs into WHMCS to manage / renew their domain? The main thing it to allow them to update the nameservers or the forwarding settings. Can you add custom activities in the what would you like to do today area? it would be nice to have the additional options there rather than just the renew domain option. Again, these different actions need to be just for the .dj extension, not all domain types. Thanks Link to comment Share on other sites More sharing options...
brian! Posted March 12, 2018 Share Posted March 12, 2018 19 hours ago, Clearview said: Is there any way to make the new fields appear when the customer logs into WHMCS to manage / renew their domain? The main thing it to allow them to update the nameservers or the forwarding settings. those features are added automatically if the registrar module, assigned to the domain, supports them.... if they don't support them, they aren't added. 19 hours ago, Clearview said: Can you add custom activities in the what would you like to do today area? it would be nice to have the additional options there rather than just the renew domain option. Again, these different actions need to be just for the .dj extension, not all domain types. the problem you will have is that WHMCS doesn't store nameserver, forwarding settings etc for domains - they are pulled from, and sent back to, the registrar when required... therefore, you will probably need to update your custom script. in an ideal world, you'd just go back to your developer and get it to tweak it accordingly - but if he's gone missing, then you may need to contact another developer to update/rewrite the script... that's even assuming that the registry supports changes to nameservers etc in that way. the only other built-in way to do it would be to get the user to open a support ticket when they want to make such changes... and then you'd have to manually apply them (assuming you can do that, e.g via registry site etc). Link to comment Share on other sites More sharing options...
Recommended Posts