lanquest Posted March 25, 2010 Share Posted March 25, 2010 Great mod - many thanks.. 0 Quote Link to comment Share on other sites More sharing options...
DataViking Posted March 29, 2010 Share Posted March 29, 2010 Thank you very much for the addon 0 Quote Link to comment Share on other sites More sharing options...
martynh Posted April 2, 2010 Share Posted April 2, 2010 Hi, how do i change the date format from "Year - month - day" to "day - month - year" I have played about with it but seems to stop it from showing once changed thanks 0 Quote Link to comment Share on other sites More sharing options...
sohouk Posted July 26, 2010 Share Posted July 26, 2010 That is a nice script and exactly what is needed. Can someone tell me what I alter to set the number of days to 30, rather than 60? UK names cannot be renewed more than 30-days in advance, so although they appear in the list, they can’t actually be renewed. Trevor 0 Quote Link to comment Share on other sites More sharing options...
scurrell Posted July 26, 2010 Share Posted July 26, 2010 UK names cannot be renewed more than 30-days in advance, so although they appear in the list, they can’t actually be renewed. UK domain names can be renewed up to 5 months in advance. 0 Quote Link to comment Share on other sites More sharing options...
RPS Posted July 26, 2010 Author Share Posted July 26, 2010 There's one posted in the thread for 30-60 days, you can modify it so it shows 1-30 days away if you want. 0 Quote Link to comment Share on other sites More sharing options...
sohouk Posted July 26, 2010 Share Posted July 26, 2010 That was my question - how do you modify it to simply show 30-days. I do not know enough to change the relevant elements. Trevor 0 Quote Link to comment Share on other sites More sharing options...
RPS Posted July 26, 2010 Author Share Posted July 26, 2010 Well, you gotta make an attempt here.. Look for the code that works for 30 to 60 days. Post the code, then *try* to change what you think would be a logical change, to make it go from 30 to 60, to 1 to 30. So #1, post the code for the 30-60. #2, look at the code, think about what you would change on it to go from 30-60, to 1-30. Post both of those, then I'll check out the code for #2, and let you know what else needs to be changed. 0 Quote Link to comment Share on other sites More sharing options...
sohouk Posted July 26, 2010 Share Posted July 26, 2010 Firstly, I have no idea how the code works. I am simply trying to adjust something that provides a facility that should be in WHMCS as a default. I can see no references in any of the code to 30, 60 or indeed any other range of days which was the purpose of my question. And I didn’t want a range, I simply wanted to have a fixed figure of 30-days. Looking at the code, the business element seems to be this: {php} $date = date("Ymd",mktime(0,0,0,date("m")+2,date("d"),date("Y"))); $i=1; $result = mysql_query("SELECT * FROM tbldomains WHERE userid='".$_SESSION['uid']."' AND expirydate<'".$date."' AND status='Active' ORDER BY `expirydate` ASC "); while($data = mysql_fetch_array($result)) but, as I said – I can’t see any clue as to where the number of days is determined. There is no 30 or 60 anywhere in that code. Trevor 0 Quote Link to comment Share on other sites More sharing options...
RPS Posted July 26, 2010 Author Share Posted July 26, 2010 You didn't read through the thread though.. you would have found this post if you did: http://forum.whmcs.com/showpost.php?p=51938&postcount=36 Read through the post/code. To comment a line in PHP, you add two forwardslashes to the left of the line. So: $hello this is a php line To comment that, you would change it to read //$hello this is a php line To remove the comment, you just remove the two slashes. Uncomment the line that says "between", then change the numbers to what you think they should be. Post your final code. 0 Quote Link to comment Share on other sites More sharing options...
sohouk Posted July 26, 2010 Share Posted July 26, 2010 You are correct. I didn’t read the thread all the way through. I got to the part where the code I wanted worked and did what I wanted. I did not have time to read a further six pages The example you refer to is easy to amend and works perfectly. Its just what I wanted to encourage our lazy clients to renew. They normally only bother when the name has expired! 0 Quote Link to comment Share on other sites More sharing options...
RPS Posted July 26, 2010 Author Share Posted July 26, 2010 It's all good! You mind posting your code so others know what you did? 0 Quote Link to comment Share on other sites More sharing options...
sohouk Posted July 26, 2010 Share Posted July 26, 2010 I didn't do anything except what you advised. I looked at the code in the link you suggested. I then uncommented the lines that determined the display of the domains dependant on whether they were <30 &etc more days to expiry. I commented out the lines that were not relevant. 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.