Giannis Posted September 11, 2007 Share Posted September 11, 2007 Hello I use WHM in greece and for gr domains the minimum registration time for is 2 years. By editing one of the predefined reports i took this code <?php $reportdata["title"] = "Domains"; $reportdata["description"] = ""; $reportdata["tableheadings"] = array("Item Name","Bienially Revenue","Annual Revenue","Total Yearly Revenue"); $annually = 0; $query = "SELECT * FROM tbldomains WHERE status!='Expired'"; $result=mysql_query($query); while($data = mysql_fetch_array($result)){ $amount = $data["recurringamount"]; $registrationperiod = $data["registrationperiod"]; if ($registrationperiod<2) {$registrationperiod=2; } $annually=$annually+($amount/$registrationperiod); } $annually=number_format($annually,2,".",""); $servertotal=number_format($annually,2,".",""); $overalltotal=$overalltotal+$servertotal; $reportdata["tablevalues"][] = array("Domains",$CONFIG["CurrencySymbol"]."0.00",$CONFIG["CurrencySymbol"]."$annually",$CONFIG["CurrencySymbol"]."$servertotal"); $overalltotal=number_format($overalltotal,2,".",""); ?> i want to display all gr domains under Bienially Revenue and all the other domains i have .com .net under Annualy and also the total of all domains at total section. Could some one help me on fixing this? Thank You 0 Quote Link to comment Share on other sites More sharing options...
Jordan Posted September 11, 2007 Share Posted September 11, 2007 When you are adding domain names to Domain Pricing (admin/configdomains.php) on WHMCS, you specify the amount of REQUIRED years under "Registration Period." When that domain extension appears, the client has to pay the minimum requirement. So if a .NU registration period is two years, you have "2" under the registration period, and of course you have the registration price/tranfser/renewal rates reflect that two year period. 0 Quote Link to comment Share on other sites More sharing options...
Giannis Posted September 11, 2007 Author Share Posted September 11, 2007 everything is ok with domain order i want just to have a detailed report about domains with this script. 0 Quote Link to comment Share on other sites More sharing options...
Jordan Posted September 11, 2007 Share Posted September 11, 2007 Edit: Okay I see that you just want a report of your domain's revenues. *headdesk* 0 Quote Link to comment Share on other sites More sharing options...
Giannis Posted September 11, 2007 Author Share Posted September 11, 2007 right 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.