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 Releases
SupaUpdate: MySQL Mass Updater
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="brsy" data-source="post: 94214" data-attributes="member: 2912"><p><span style="font-size: 18px"><strong>SupaUpdate</strong></span></p><p> </p><p><span style="font-size: 12px">SupaUpdate is a quick and easy tool that can be used to set one value to a mass amount of data within a database, plus it's secure! Here is the code, put it into a PHP file and name it whatever you want so people can't find it. Afterwards, open the file using a PHP file editor, and edit lines 17-21. Save, then you're done! </span></p><p></p><p><strong><span style="font-size: 12px">Code:</span></strong></p><p>[PHP]<?php</p><p> </p><p>/*</p><p> </p><p>* Script Name: SupaUpdater</p><p> </p><p>* Script Description: Database alterations made easy.</p><p> </p><p>* Created by: ChrizPHP</p><p> </p><p>* Released on: N/A</p><p> </p><p>*</p><p> </p><p>* This script was created by ChrizPHP, on behalf of ***** -- an all-around</p><p> </p><p>* development group dedicated on providing top-quality products to the</p><p> </p><p>* internet.</p><p> </p><p>*/</p><p> </p><p> </p><p> </p><p>function filter($str) {</p><p> </p><p> mysql_real_escape_string(htmlentities($str));</p><p> </p><p>}</p><p> </p><p> </p><p> </p><p>$supa['dbDatabase'] = 'bullet'; // database that has your hotel's DB.</p><p> </p><p>$supa['dbUsername'] = 'root'; // username to connect to database (usually root)</p><p> </p><p>$supa['dbHostname'] = 'localhost'; // hostname for databases (usually localhost)</p><p> </p><p>$supa['dbPassword'] = 'abc123'; // password used to connect to database</p><p> </p><p>$supa['adminPassword'] = 'supaPassword'; // password used to sign into SupaUpdate</p><p> </p><p> </p><p> </p><p>$connect = mysql_pconnect($supa['dbHostname'], $supa['dbUsername'], $supa['dbPassword']);</p><p> </p><p>mysql_select_db($supa['dbDatabase'], $connect);</p><p> </p><p> </p><p> </p><p>if(isset($_POST['done'])) {</p><p> </p><p> $column = filter($_POST['column']); </p><p> </p><p> $value = filter($_POST['value']);</p><p> </p><p> $table = filter($_POST['table']);</p><p> </p><p> mysql_query("UPDATE ".$table." SET ".$column." = '".$value."'");</p><p> </p><p> $error = mysql_error();</p><p> </p><p> if(isset($error)) {</p><p> </p><p> die($error. '<br /><b>Refresh the page to try again.<b>');</p><p> </p><p> }</p><p> </p><p>}</p><p> </p><p> </p><p> </p><p>if(!isset($_SESSION['logged'])) { ?></p><p> </p><p><form action="" method="POST"></p><p> </p><p> <label>Administrative Password:</label></p><p> </p><p> <input type="password" name="password" /></p><p> </p><p> <input type="submit" name="login" /></p><p> </p><p></form></p><p> </p><p> <?php</p><p> </p><p> if(isset($_POST['login'])) {</p><p> </p><p> if($_POST['password'] != $supa['adminPassword']) {</p><p> </p><p> die('The password you have entered does not match the password you have set for supaUpdate. If you have not yet created a password, please edit your SupaUpdate file.');</p><p> </p><p> }</p><p> </p><p> else {</p><p> </p><p> $_SESSION['logged'] = true;</p><p> </p><p> }</p><p> </p><p> }</p><p> </p><p>}</p><p> </p><p>if(isset($_SESSION['logged'])) {</p><p> </p><p>?></p><p> </p><p><center></p><p> </p><p> <h3>supaUpdater</h3><hr /></p><p> </p><p> <form method="POST" action=""></p><p> </p><p> <label>Table Name:</label></p><p> </p><p> <input style="width:175px;" type="text" name="table" /></p><p> </p><p> <br /></p><p> </p><p> <label>Altered Column:</label></p><p> </p><p> <input style="outline: #FFF000;margin-right:19px;width:175px;" type="text" name="column" /></p><p> </p><p> <br /></p><p> </p><p> <label>New Value: </label></p><p> </p><p> <input style="margin-left:6px;width:175px;" type="text" name="value" /></p><p> </p><p> <br /><br /></p><p> </p><p> <input type="submit" style="height:30px;width:270px;" value="Make Changes!" name="done" /></p><p> </p><p> </form></p><p> </p><p></center></p><p> </p><p><?php } ?>[/PHP]</p></blockquote><p></p>
[QUOTE="brsy, post: 94214, member: 2912"] [SIZE=5][B]SupaUpdate[/B][/SIZE] [SIZE=3]SupaUpdate is a quick and easy tool that can be used to set one value to a mass amount of data within a database, plus it's secure! Here is the code, put it into a PHP file and name it whatever you want so people can't find it. Afterwards, open the file using a PHP file editor, and edit lines 17-21. Save, then you're done! [/SIZE] [SIZE=2][B][/B][/SIZE] [B][SIZE=3]Code:[/SIZE][/B] [PHP]<?php /* * Script Name: SupaUpdater * Script Description: Database alterations made easy. * Created by: ChrizPHP * Released on: N/A * * This script was created by ChrizPHP, on behalf of ***** -- an all-around * development group dedicated on providing top-quality products to the * internet. */ function filter($str) { mysql_real_escape_string(htmlentities($str)); } $supa['dbDatabase'] = 'bullet'; // database that has your hotel's DB. $supa['dbUsername'] = 'root'; // username to connect to database (usually root) $supa['dbHostname'] = 'localhost'; // hostname for databases (usually localhost) $supa['dbPassword'] = 'abc123'; // password used to connect to database $supa['adminPassword'] = 'supaPassword'; // password used to sign into SupaUpdate $connect = mysql_pconnect($supa['dbHostname'], $supa['dbUsername'], $supa['dbPassword']); mysql_select_db($supa['dbDatabase'], $connect); if(isset($_POST['done'])) { $column = filter($_POST['column']); $value = filter($_POST['value']); $table = filter($_POST['table']); mysql_query("UPDATE ".$table." SET ".$column." = '".$value."'"); $error = mysql_error(); if(isset($error)) { die($error. '<br /><b>Refresh the page to try again.<b>'); } } if(!isset($_SESSION['logged'])) { ?> <form action="" method="POST"> <label>Administrative Password:</label> <input type="password" name="password" /> <input type="submit" name="login" /> </form> <?php if(isset($_POST['login'])) { if($_POST['password'] != $supa['adminPassword']) { die('The password you have entered does not match the password you have set for supaUpdate. If you have not yet created a password, please edit your SupaUpdate file.'); } else { $_SESSION['logged'] = true; } } } if(isset($_SESSION['logged'])) { ?> <center> <h3>supaUpdater</h3><hr /> <form method="POST" action=""> <label>Table Name:</label> <input style="width:175px;" type="text" name="table" /> <br /> <label>Altered Column:</label> <input style="outline: #FFF000;margin-right:19px;width:175px;" type="text" name="column" /> <br /> <label>New Value: </label> <input style="margin-left:6px;width:175px;" type="text" name="value" /> <br /><br /> <input type="submit" style="height:30px;width:270px;" value="Make Changes!" name="done" /> </form> </center> <?php } ?>[/PHP] [/QUOTE]
Insert quotes…
Verification
Post reply
Forums
Server Development
Habbo Retros
Habbo Releases
SupaUpdate: MySQL Mass Updater
Top