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
Reporting System
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: 419331" data-attributes="member: 596"><p>Your Script is tripling my entry into the Database <img src="/styles/default/xenforo/smilies/emojione/frown.png" class="smilie" loading="lazy" alt=":(" title="Frown :(" data-shortname=":(" /></p><p>Error: <strong>Fatal error</strong>: Call to a member function secure() on null in <strong>/Applications/XAMPP/xamppfiles/htdocs/app/tpl/skins/Habbo/report.php</strong> on line <strong>79</strong></p><p><strong></strong></p><p><strong>NEW EDIT:</strong></p><p><strong></strong></p><p><strong>[PHP]<?php if(isset($_POST['report_submit']))</strong></p><p><strong> {</strong></p><p><strong> $report_type = $engine->secure($_POST['report_type']);</strong></p><p><strong> $report_info = $engine->secure($_POST['report_info']);</strong></p><p><strong> $report_more = $engine->secure($_POST['report_more']);</strong></p><p><strong> $report_staff = $engine->secure($_POST['report_staff']);</strong></p><p><strong> $report_agree = $engine->secure($_POST['report_agree']);</strong></p><p><strong></strong></p><p><strong> if((($report_type == "staff_complaint") ||($report_type == "request_furni") || ($report_type == "suggestion_box") || !empty($_POST['report_agree'])))</strong></p><p><strong> {</strong></p><p><strong> $engine->query("INSERT INTO `staff_report` (id,complaint,staff,explanation) VALUES ('".$report_type."','".$report_info."', '".$report_more."','".$report_staff."')");</strong></p><p><strong> echo 'We have successfuly reveived your report!';</strong></p><p><strong> } </strong></p><p><strong> else</strong></p><p><strong> {</strong></p><p><strong> echo 'Oh no! Error Somewhere';</strong></p><p><strong> } </strong></p><p><strong> }</strong></p><p><strong> ?> </strong></p><p><strong> </strong></p><p><strong><form method="post" class="form" name ="report_submit"></strong></p><p><strong><div class="form-group"></strong></p><p><strong><label for="disabledTextInput"><b>Please choose one of the following</b></label></strong></p><p><strong><div class="col-sm-10"></strong></p><p><strong><select name="report_type" class="form-control"></strong></p><p><strong> <option value="staff_complaint">Complaint against a member of staff</option></strong></p><p><strong> <option value="request_furni">Request a furni to be added or fixed</option></strong></p><p><strong> <option value="suggestion_box">Comment/Suggestion</option></strong></p><p><strong> </select></strong></p><p><strong> </div></strong></p><p><strong> </div></strong></p><p><strong> <br/></strong></p><p> <strong><div class="form-group"></strong></p><p><strong><label for="disabledTextInput"><b>Please choose a member of staff (If you are reporting/complimenting a staff member)</b></label></strong></p><p><strong><div class="col-sm-10"></strong></p><p><strong><div class="col-sm-10"></strong></p><p><strong><select name="report_staff" class="form-control"></strong></p><p><strong><?php</strong></p><p><strong>$getStaff = mysql_query("SELECT username FROM users WHERE rank >= '3'");</strong></p><p> <strong>while($staffUser = mysql_fetch_array($getStaff)){</strong></p><p><strong> echo'</strong></p><p><strong> <option value="NA">N\A</option></strong></p><p><strong> <option disabled>-------------------------</option></strong></p><p><strong> <option value="report_staff">'.$staffUser['username'].'</option>';</strong></p><p><strong>}</strong></p><p><strong>?></strong></p><p><strong></select></strong></p><p><strong></div></strong></p><p><strong></div></strong></p><p><strong></div></strong></p><p><strong><br/></strong></p><p><strong><div class="form-group"></strong></p><p><strong><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></strong></p><p><strong><div class="col-sm-10"></strong></p><p><strong><textarea class="form-control" rows="5" name="report_info" maxlength="255" style="width:350px;height:75px;resize:none"></textarea></strong></p><p><strong></div></strong></p><p><strong></div></strong></p><p><strong><br/></strong></p><p><strong><div class="form-group"></strong></p><p><strong><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></strong></p><p><strong><div class="col-sm-10"></strong></p><p><strong><textarea class="form-control" rows="3" name="report_extra" maxlength="255" class="ss-q-short" style="width:350px;height:75px;resize:none"></textarea></strong></p><p><strong></div></strong></p><p><strong></div></strong></p><p><strong><br/> </strong></p><p><strong><div class="checkbox"></strong></p><p><strong><label><input name="report_agree" value="1" type="checkbox">I am aware that if my report is spam, my account could be banned.</label></strong></p><p><strong></div></strong></p><p><strong><br></strong></p><p><strong><input type="submit" value="Submit" name="report_submit" class="submit" style="float left"></strong></p><p><strong></form>[/PHP]</strong></p><p><strong></strong></p><p><strong>Still Insert Blank SQL </strong></p><p><strong></strong></p><p><strong>Image:</strong></p><p><strong><img src="http://i68.tinypic.com/sqo37t.png" alt="" class="fr-fic fr-dii fr-draggable " style="" /> </strong></p><p><strong></strong></p><p><strong><img src="http://i65.tinypic.com/2a0nhif.png" alt="" class="fr-fic fr-dii fr-draggable " style="" /> </strong></p><p><strong>SQL Table:</strong></p><p><strong>[PHP]CREATE TABLE `staff_report` (</strong></p><p><strong> `id` int(10) UNSIGNED NOT NULL,</strong></p><p><strong> `complaint` varchar(64) DEFAULT NULL,</strong></p><p><strong> `staff` varchar(25) DEFAULT NULL,</strong></p><p><strong> `explanation` text NOT NULL,</strong></p><p><strong> `moreinfo` text NOT NULL</strong></p><p><strong>) ENGINE=InnoDB DEFAULT CHARSET=utf8;[/PHP]</strong></p><p><strong></strong></p><p><strong></strong></p><p>[doublepost=1506723334,1506661451][/doublepost]Bump this thread. It inserting Blank Rows in my database.</p></blockquote><p></p>
[QUOTE="Detox, post: 419331, member: 596"] Your Script is tripling my entry into the Database :( Error: [B]Fatal error[/B]: Call to a member function secure() on null in [B]/Applications/XAMPP/xamppfiles/htdocs/app/tpl/skins/Habbo/report.php[/B] on line [B]79 NEW EDIT: [PHP]<?php if(isset($_POST['report_submit'])) { $report_type = $engine->secure($_POST['report_type']); $report_info = $engine->secure($_POST['report_info']); $report_more = $engine->secure($_POST['report_more']); $report_staff = $engine->secure($_POST['report_staff']); $report_agree = $engine->secure($_POST['report_agree']); if((($report_type == "staff_complaint") ||($report_type == "request_furni") || ($report_type == "suggestion_box") || !empty($_POST['report_agree']))) { $engine->query("INSERT INTO `staff_report` (id,complaint,staff,explanation) VALUES ('".$report_type."','".$report_info."', '".$report_more."','".$report_staff."')"); echo 'We have successfuly reveived your report!'; } else { echo 'Oh no! Error Somewhere'; } } ?> <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="staff_complaint">Complaint against a member of staff</option> <option value="request_furni">Request a furni to be added or fixed</option> <option value="suggestion_box">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"> <?php $getStaff = mysql_query("SELECT username FROM users WHERE rank >= '3'"); while($staffUser = mysql_fetch_array($getStaff)){ echo' <option value="NA">N\A</option> <option disabled>-------------------------</option> <option value="report_staff">'.$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_extra" 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="1" 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] Still Insert Blank SQL Image: [IMG]http://i68.tinypic.com/sqo37t.png[/IMG] [IMG]http://i65.tinypic.com/2a0nhif.png[/IMG] SQL Table: [PHP]CREATE TABLE `staff_report` ( `id` int(10) UNSIGNED NOT NULL, `complaint` varchar(64) DEFAULT NULL, `staff` varchar(25) DEFAULT NULL, `explanation` text NOT NULL, `moreinfo` text NOT NULL ) ENGINE=InnoDB DEFAULT CHARSET=utf8;[/PHP] [/B] [doublepost=1506723334,1506661451][/doublepost]Bump this thread. It inserting Blank Rows in my database. [/QUOTE]
Insert quotes…
Verification
Post reply
Forums
Server Development
Habbo Retros
Habbo Q&A
Reporting System
Top