justravis Posted September 9, 2008 Share Posted September 9, 2008 Trying to convert a 1 or 2 digit number representing a month to a 2 digit number including a leading 0 when necessary: $skr_grad_date="$_REQUEST[gradyr]-" . date("m", mktime(0,0,0,$_REQUEST[gradmo])) . '-00'; Warning: mktime() expects parameter 4 to be long, string given in /home/dm/public_html/dmd/app/mentee/index.pwr on line 212 Any suggestions would be greatly appreciated! Link to comment https://forums.phpfreaks.com/topic/123492-solved-mktime-expects-parameter-4-to-be-long/ Share on other sites More sharing options...
justravis Posted September 10, 2008 Author Share Posted September 10, 2008 As you probably guessed, it was related to the REQUEST field not having a value. It's best to debug by echoing. Sorry. Link to comment https://forums.phpfreaks.com/topic/123492-solved-mktime-expects-parameter-4-to-be-long/#findComment-638119 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.