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
[Help] RevCMS, GrapeASE, Can't add bans
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="Tando" data-source="post: 271012" data-attributes="member: 8322"><p>Ofcourse.</p><p>As you can see, it says the user was banned successfully, but the ban is not added to the database.</p><p></p><p><img src="http://farbetaler.no/upload/uploads/p1.PNG" alt="" class="fr-fic fr-dii fr-draggable " style="" /></p><p><img src="http://farbetaler.no/upload/uploads/p2.PNG" alt="" class="fr-fic fr-dii fr-draggable " style="" /></p><p><img src="http://farbetaler.no/upload/uploads/p3.PNG" alt="" class="fr-fic fr-dii fr-draggable " style="" /></p><p></p><p>Here's the code of the addban2.php page.</p><p>[PHP]<link rel="stylesheet" href="{url}/app/tpl/skins/{skin}/hk/styles/global.css" type="text/css"></p><p><div id="main"></p><p> <div id="links"></div></p><p> <div id="header"><img src="{url}/app/tpl/skins/{skin}/images/logo.png" align=right style="margin-right: 480px; margin-top: 5px;"></p><p> <div id="logo"></p><p> <div id="logo_text"></p><p> <!-- class="logo_colour", allows you to change the color of the logo text --></p><p> <h1>{hotelname} Housekeeping -- Welcome {username}</h1></p><p> </div></p><p> </div></p><p> </div></p><p> <div id="site_content"></p><p> <div id="sidebar_container"></p><p> <!-- insert your sidebar items here --></p><p> <div class="sidebar"></p><p> <div class="sidebar_top"></div></p><p> <div class="sidebar_item"></p><p> <br /></p><p> [ <a href='dash'>Return to Dashboard</a> ] [ <a href='logout'>Log out</a> ]<br /> <br /></p><p> <p></p><p> <?php if(mysql_result(mysql_query("SELECT rank FROM users WHERE id = '" . $_SESSION['user']['id'] . "'"), 0) >= 5)</p><p> { ?></p><p> Player Management <br /> <img src='../app/tpl/skins/<?php echo $_CONFIG['template']['style']; ?>/hk/images/line.png'> <br /></p><p> </p><p> &raquo; <a href='vip'>Give a user Regular VIP</a> <br /></p><p> </p><p> &raquo; <a href='edit'>Edit a users account</a> <br /></p><p> <br /></p><p> Administration <br /> <img src='../app/tpl/skins/<?php echo $_CONFIG['template']['style']; ?>/hk/images/line.png'> <br /></p><p> &raquo; <a href='news'>Post news article</a><br /></p><p> &raquo; <a href='delnews'>Delete a news article (By ID)</a><br /></p><p> &raquo; <a href='cmdlogs'>Command logs</a><br />&raquo; <a href='motd'>Change welcome message</a><br />&raquo; <a href='empty'>Empty a table</a><br />&raquo; <a href='timer'>Change the Credits & Pixels timer</a><br /></p><p> <br /></p><p> <?php } if(mysql_result(mysql_query("SELECT rank FROM users WHERE id = '" . $_SESSION['user']['id'] . "'"), 0) >= 4) { ?></p><p> Moderation <br /> <img src='../app/tpl/skins/<?php echo $_CONFIG['template']['style']; ?>/hk/images/line.png'> <br /></p><p> &raquo; <a href='banlist'>Ban List</a> <br /></p><p> &raquo; <a href='ip'>IP lookup</a> <br /></p><p> &raquo; <a href='unban'>Unban a User</a> <br />&raquo; <a href='addban'>Ban a user</a><br /></p><p> <br /></p><p> Badges <br /> <img src='../app/tpl/skins/<?php echo $_CONFIG['template']['style']; ?>/hk/images/line.png'> <br /></p><p> &raquo; <a href='listbadge'>List badges</a><br />&raquo; <a href='addbadge'>Add a badge</a><br />&raquo; <a href='delbadge'>Delete a badge</a><br /></p><p> </p><p> <?php } ?></p><p> <br /></p><p> Statistics<br /></p><p> <img src='../app/tpl/skins/<?php echo $_CONFIG['template']['style']; ?>/hk/images/line.png'> <br /></p><p> Server Status:</p><p> {status} <br /></p><p> {online} user(s) online <br /></p><p> </p><p> </p></p><p> </div></p><p> <div class="sidebar_base"></div></p><p> </div></p><p> </div></p><p> <div id="content_container"></p><p></p><p> <div id="content"></p><p> <!-- insert the page content here --></p><p> <br /> <?php</p><p>include_once('databaseconfig.php');</p><p></p><p>{</p><p>$ban_id = mysql_real_escape_string($_POST['ban_id']);</p><p>$type = mysql_real_escape_string($_POST['type']);</p><p>$user = mysql_real_escape_string($_POST['username']);</p><p>$reason = mysql_real_escape_string($_POST['reason']);</p><p>$author = mysql_result(mysql_query("SELECT username FROM users WHERE id = '".$_SESSION['user']['id']."' LIMIT 1"), 0);</p><p>$expire = mysql_real_escape_string($_POST['expire']);</p><p></p><p>mysql_query("INSERT INTO bans (id,bantype,value,reason,added_by,expire) VALUES ('$ban_id','$type','$user','$reason','$author','$expire')");</p><p>echo ("Ban has been added!");</p><p>}</p><p></p><p></p><p></p><p>?></p><p><html></p><p><body></p><p><h1>Okay. If you see 'Ban has been added!' at the top, then it has completed successfully.</h1></p><p></p><p></p><p></div></p><p></p><p> </div></p><p> </div></p><p> </div></p><p> <font color="black"> <center>Powered by GrapeASE by Grapefruit - Design by Grapefruit</center><br /> <center>Implemented into RevCMS by Kryptos</center><br /></p><p>[/PHP]</p></blockquote><p></p>
[QUOTE="Tando, post: 271012, member: 8322"] Ofcourse. As you can see, it says the user was banned successfully, but the ban is not added to the database. [IMG]http://farbetaler.no/upload/uploads/p1.PNG[/IMG] [IMG]http://farbetaler.no/upload/uploads/p2.PNG[/IMG] [IMG]http://farbetaler.no/upload/uploads/p3.PNG[/IMG] Here's the code of the addban2.php page. [PHP]<link rel="stylesheet" href="{url}/app/tpl/skins/{skin}/hk/styles/global.css" type="text/css"> <div id="main"> <div id="links"></div> <div id="header"><img src="{url}/app/tpl/skins/{skin}/images/logo.png" align=right style="margin-right: 480px; margin-top: 5px;"> <div id="logo"> <div id="logo_text"> <!-- class="logo_colour", allows you to change the color of the logo text --> <h1>{hotelname} Housekeeping -- Welcome {username}</h1> </div> </div> </div> <div id="site_content"> <div id="sidebar_container"> <!-- insert your sidebar items here --> <div class="sidebar"> <div class="sidebar_top"></div> <div class="sidebar_item"> <br /> [ <a href='dash'>Return to Dashboard</a> ] [ <a href='logout'>Log out</a> ]<br /> <br /> <p> <?php if(mysql_result(mysql_query("SELECT rank FROM users WHERE id = '" . $_SESSION['user']['id'] . "'"), 0) >= 5) { ?> Player Management <br /> <img src='../app/tpl/skins/<?php echo $_CONFIG['template']['style']; ?>/hk/images/line.png'> <br /> » <a href='vip'>Give a user Regular VIP</a> <br /> » <a href='edit'>Edit a users account</a> <br /> <br /> Administration <br /> <img src='../app/tpl/skins/<?php echo $_CONFIG['template']['style']; ?>/hk/images/line.png'> <br /> » <a href='news'>Post news article</a><br /> » <a href='delnews'>Delete a news article (By ID)</a><br /> » <a href='cmdlogs'>Command logs</a><br />» <a href='motd'>Change welcome message</a><br />» <a href='empty'>Empty a table</a><br />» <a href='timer'>Change the Credits & Pixels timer</a><br /> <br /> <?php } if(mysql_result(mysql_query("SELECT rank FROM users WHERE id = '" . $_SESSION['user']['id'] . "'"), 0) >= 4) { ?> Moderation <br /> <img src='../app/tpl/skins/<?php echo $_CONFIG['template']['style']; ?>/hk/images/line.png'> <br /> » <a href='banlist'>Ban List</a> <br /> » <a href='ip'>IP lookup</a> <br /> » <a href='unban'>Unban a User</a> <br />» <a href='addban'>Ban a user</a><br /> <br /> Badges <br /> <img src='../app/tpl/skins/<?php echo $_CONFIG['template']['style']; ?>/hk/images/line.png'> <br /> » <a href='listbadge'>List badges</a><br />» <a href='addbadge'>Add a badge</a><br />» <a href='delbadge'>Delete a badge</a><br /> <?php } ?> <br /> Statistics<br /> <img src='../app/tpl/skins/<?php echo $_CONFIG['template']['style']; ?>/hk/images/line.png'> <br /> Server Status: {status} <br /> {online} user(s) online <br /> </p> </div> <div class="sidebar_base"></div> </div> </div> <div id="content_container"> <div id="content"> <!-- insert the page content here --> <br /> <?php include_once('databaseconfig.php'); { $ban_id = mysql_real_escape_string($_POST['ban_id']); $type = mysql_real_escape_string($_POST['type']); $user = mysql_real_escape_string($_POST['username']); $reason = mysql_real_escape_string($_POST['reason']); $author = mysql_result(mysql_query("SELECT username FROM users WHERE id = '".$_SESSION['user']['id']."' LIMIT 1"), 0); $expire = mysql_real_escape_string($_POST['expire']); mysql_query("INSERT INTO bans (id,bantype,value,reason,added_by,expire) VALUES ('$ban_id','$type','$user','$reason','$author','$expire')"); echo ("Ban has been added!"); } ?> <html> <body> <h1>Okay. If you see 'Ban has been added!' at the top, then it has completed successfully.</h1> </div> </div> </div> </div> <font color="black"> <center>Powered by GrapeASE by Grapefruit - Design by Grapefruit</center><br /> <center>Implemented into RevCMS by Kryptos</center><br /> [/PHP] [/QUOTE]
Insert quotes…
Verification
Post reply
Forums
Server Development
Habbo Retros
Habbo Q&A
[Help] RevCMS, GrapeASE, Can't add bans
Top