Lumbergh Posted July 25, 2006 Share Posted July 25, 2006 Alright, so I have easyban installed on my board (2.1), and I'm modifying it a little. I want to input a time function so that I set the amount of time the user is banned for, and when the time is up it places them into their old group. I have it so that when the user gets banned, it takes mgroup2=mgroup, so that it saves the old group, and it works fine. Now i'm on to the time part... which I can't figure out. [code]<td class="row1" colspan=2 width="40%" valign="top">For how long?<td class="row2" colspan=2 width="40%" valign="top"> <input type="text" name="banamount">[/code]There is what I have in the template html for easy ban[code] // For how long? if($ibforums->input['banamount']!=0) { $bantime = $ibforums->input['banamount']; $unbantime = strtotime($bantime); $this->ipsclass->DB->query("UPDATE ibf_members SET bantime=$unbantime WHERE id=".$id); }[/code]Thats the little snippet of code I have for the time.Right now the problem is that the banamount isn't seeming to go through. I echo'd the banamount before $bantime etc, and it came up with a blank page, and I can't figure out why.EDIT: Sorry, I forgot to mention that it gives me the same timestamp in ibf_members under bantime, of 1153717200, which is interesting.Is this even the best way to do this? Is my coding all wrong anyway?Thanks for the help! Link to comment https://forums.phpfreaks.com/topic/15558-invision-board-modify-help-timemysql/ Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.