Menu
Forums
All threads
Latest threads
New posts
Trending threads
New posts
Search forums
Trending
What's new
New posts
New profile posts
Latest activity
Members
Current visitors
New profile posts
Search profile posts
Upgrades
Log in
Register
What's new
Search
Search
Search titles only
By:
All threads
Latest threads
New posts
Trending threads
New posts
Search forums
Menu
Log in
Register
Navigation
Install the app
Install
More options
Contact us
Close Menu
Forums
Server Development
Habbo Retros
Habbo Q&A
RevCMS Report Tool
JavaScript is disabled. For a better experience, please enable JavaScript in your browser before proceeding.
You are using an out of date browser. It may not display this or other websites correctly.
You should upgrade or use an
alternative browser
.
Reply to thread
Message
<blockquote data-quote="Detox" data-source="post: 426544" data-attributes="member: 596"><p>Hello Dev,</p><p>I have attempted to create a report tool and kinda works like I wanted but not fully working!</p><p>So when I go to report page, it will not throw off error that I'm requesting it to do. It will insert blank stuff into the database. But I need it to where you must fill out the forum and to agree to the terms.</p><p></p><p>[PHP]<?php </p><p></p><p>if(isset($_POST['report_submit']))</p><p> {</p><p> $report_id = mysql_real_escape_string($_POST['report_id']);</p><p> $report_type = mysql_real_escape_string($_POST['report_type']);</p><p> $report_info = mysql_real_escape_string($_POST['report_info']);</p><p> $report_more = mysql_real_escape_string($_POST['report_more']);</p><p> $report_staff = mysql_real_escape_string($_POST['report_staff']);</p><p></p><p> if((($report_type == "Complaint against a member of staff") ||($report_type == "Request a furni to be added or fixed") || ($report_type == "Comment/Suggestion") || !empty($_POST['report_agree'])))</p><p> {</p><p> mysql_query("INSERT INTO `staff_report` (id,complaint,staff,explanation, moreinfo) VALUES ('".$report_id."','".$report_type."', '".$report_staff."' ,'".$report_info."', '".$report_more."')");</p><p> echo '</p><p> <div id="container"></p><p> <div id="content" style="position: relative" class="clearfix"></p><p> <div class="alert alert-info" style="margin-bottom: 10px;width:570px;height:3%;"></p><p> <strong><center>We have successfully received your report!</strong></center></div></div></div>';</p><p> } </p><p> else</p><p> {</p><p> echo '</p><p> <div class="rounded rounded-red"></p><p></p><p> Please Complete the forum!</p><p></p><p> </div>';</p><p> } </p><p> }</p><p> ?> </p><p> </p><p><form method="post" class="form" name ="report_submit"></p><p><div class="form-group"></p><p><label for="disabledTextInput"><b>Please choose one of the following</b></label></p><p><div class="col-sm-10"></p><p><select name="report_type" class="form-control"></p><p> <option value="Complaint against a member of staff">Complaint against a member of staff</option></p><p> <option value="Request a furni to be added or fixed">Request a furni to be added or fixed</option></p><p> <option value="Comment/Suggestion">Comment/Suggestion</option></p><p> </select></p><p> </div></p><p> </div></p><p> <br/></p><p><div class="form-group"></p><p><label for="disabledTextInput"><b>Please choose a member of staff (If you are reporting/complimenting a staff member)</b></label></p><p><div class="col-sm-10"></p><p><div class="col-sm-10"></p><p><select name="report_staff" class="form-control"></p><p><option value="N/A">N/A</option></p><p> <option disabled>-------------------------</option></p><p><?php</p><p>$getStaff = mysql_query("SELECT username FROM users WHERE rank >= '3'");</p><p> while($staffUser = mysql_fetch_array($getStaff)){</p><p> echo'</p><p> <option value="'. $staffUser['username'] .'">'.$staffUser['username'].'</option>';</p><p>}</p><p>?></p><p></select></p><p></div></p><p></div></p><p></div></p><p><br/></p><p><div class="form-group"></p><p><label for="exampleInputEmail1"><b>Please explain what you are reporting/suggesting or what is wrong with the furni you are asking to be fixed</b></label></p><p><div class="col-sm-10"></p><p><textarea class="form-control" rows="5" name="report_info" maxlength="255" style="width:350px;height:75px;resize:none"></textarea></p><p></div></p><p></div></p><p><br/></p><p><div class="form-group"></p><p><label for="exampleInputEmail1"><b>Would you like to add anything?</b><br><i>Proof? Pictures of the furni, anything else you think is important?! Leave it here!</i></label></p><p><div class="col-sm-10"></p><p><textarea class="form-control" rows="3" name="report_more" maxlength="255" class="ss-q-short" style="width:350px;height:75px;resize:none"></textarea></p><p></div></p><p></div></p><p><br/> </p><p><div class="checkbox"></p><p><label><input name="report_agree" value="0" type="checkbox">I am aware that if my report is spam, my account could be banned.</label></p><p></div></p><p><br></p><p><input type="submit" value="Submit" name="report_submit" class="submit" style="float left"></p><p></form>[/PHP]</p></blockquote><p></p>
[QUOTE="Detox, post: 426544, member: 596"] Hello Dev, I have attempted to create a report tool and kinda works like I wanted but not fully working! So when I go to report page, it will not throw off error that I'm requesting it to do. It will insert blank stuff into the database. But I need it to where you must fill out the forum and to agree to the terms. [PHP]<?php if(isset($_POST['report_submit'])) { $report_id = mysql_real_escape_string($_POST['report_id']); $report_type = mysql_real_escape_string($_POST['report_type']); $report_info = mysql_real_escape_string($_POST['report_info']); $report_more = mysql_real_escape_string($_POST['report_more']); $report_staff = mysql_real_escape_string($_POST['report_staff']); if((($report_type == "Complaint against a member of staff") ||($report_type == "Request a furni to be added or fixed") || ($report_type == "Comment/Suggestion") || !empty($_POST['report_agree']))) { mysql_query("INSERT INTO `staff_report` (id,complaint,staff,explanation, moreinfo) VALUES ('".$report_id."','".$report_type."', '".$report_staff."' ,'".$report_info."', '".$report_more."')"); echo ' <div id="container"> <div id="content" style="position: relative" class="clearfix"> <div class="alert alert-info" style="margin-bottom: 10px;width:570px;height:3%;"> <strong><center>We have successfully received your report!</strong></center></div></div></div>'; } else { echo ' <div class="rounded rounded-red"> Please Complete the forum! </div>'; } } ?> <form method="post" class="form" name ="report_submit"> <div class="form-group"> <label for="disabledTextInput"><b>Please choose one of the following</b></label> <div class="col-sm-10"> <select name="report_type" class="form-control"> <option value="Complaint against a member of staff">Complaint against a member of staff</option> <option value="Request a furni to be added or fixed">Request a furni to be added or fixed</option> <option value="Comment/Suggestion">Comment/Suggestion</option> </select> </div> </div> <br/> <div class="form-group"> <label for="disabledTextInput"><b>Please choose a member of staff (If you are reporting/complimenting a staff member)</b></label> <div class="col-sm-10"> <div class="col-sm-10"> <select name="report_staff" class="form-control"> <option value="N/A">N/A</option> <option disabled>-------------------------</option> <?php $getStaff = mysql_query("SELECT username FROM users WHERE rank >= '3'"); while($staffUser = mysql_fetch_array($getStaff)){ echo' <option value="'. $staffUser['username'] .'">'.$staffUser['username'].'</option>'; } ?> </select> </div> </div> </div> <br/> <div class="form-group"> <label for="exampleInputEmail1"><b>Please explain what you are reporting/suggesting or what is wrong with the furni you are asking to be fixed</b></label> <div class="col-sm-10"> <textarea class="form-control" rows="5" name="report_info" maxlength="255" style="width:350px;height:75px;resize:none"></textarea> </div> </div> <br/> <div class="form-group"> <label for="exampleInputEmail1"><b>Would you like to add anything?</b><br><i>Proof? Pictures of the furni, anything else you think is important?! Leave it here!</i></label> <div class="col-sm-10"> <textarea class="form-control" rows="3" name="report_more" maxlength="255" class="ss-q-short" style="width:350px;height:75px;resize:none"></textarea> </div> </div> <br/> <div class="checkbox"> <label><input name="report_agree" value="0" type="checkbox">I am aware that if my report is spam, my account could be banned.</label> </div> <br> <input type="submit" value="Submit" name="report_submit" class="submit" style="float left"> </form>[/PHP] [/QUOTE]
Insert quotes…
Verification
Post reply
Forums
Server Development
Habbo Retros
Habbo Q&A
RevCMS Report Tool
Top