Find this useful? Enter your email to receive occasional updates for securing PHP code.
Signing you up...
Thank you for signing up!
PHP Decode
<?php $config['db'] = array ( 'host' => 'localhost', 'username' => 'root', 'password' ..
Decoded Output download
<?php
$config['db'] = array (
'host' => 'localhost',
'username' => 'root',
'password' => '',
'charset' => 'utf8',
'dbname' => 'database45'
);
$connection = new PDO('mysql:host=' . $config['db']['host'] . ';charset=' . $config['db']['charset'] . ';dbname=' . $config['db']['dbname'] , $config['db']['username'] , $config['db']['password'] );
?>
<?php
function def()
{?>
<a href="?p=except" class="btn btn-default" aria-label="Left Align"> </a>
<a href="?p=all" class="btn btn-default" aria-label="Left Align"> </a>
<?php } ?>
<html>
<head>
<meta charset="utf-8"/>
<title></title>
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css" integrity="sha384-BVYiiSIFeK1dGmJRAkycuHAHRg32OmUcww7on3RYdg4Va+PmSTsz/K68vbdEjh4u" crossorigin="anonymous">
<style>
body{
direction: rtl;
text-align: right;
}
</style>
</head>
<body>
<?php
if(isset($_GET['p'])){
if($_GET['p'] == 'except' ){
if(isset($_GET['userid'])){
$userid = $_GET['userid'];
$query = "SELECT * FROM tbl1 WHERE id = $userid ";
$stmt = $connection->prepare($query);
$stmt->bindColumn('id' , $id);
$stmt->bindColumn('nam' , $name);
$stmt->bindColumn('doreh' , $doreh);
$params = array( 1 , 1 );
$stmt->execute();
echo "<table border=\"1\">
";
while($stmt->fetch()){
echo <<<EOS
$name $id $doreh .
EOS;
}
echo "</table>";
} else{
$query = "SELECT * FROM tbl1 WHERE 1";
$stmt = $connection->prepare($query);
$stmt->bindColumn('id' , $id);
$stmt->bindColumn('nam' , $name);
$stmt->bindColumn('doreh' , $doreh);
$params = array( 1 , 1 );
$stmt->execute();
echo "<table border=\"1\">
";
while($stmt->fetch()){
echo <<<EOS
<tr>
<td>$id</td>
<td>$name</td>
<td>$doreh</td>
<td><a href='?p=except&userid=$id'></a></td>
</tr>
EOS;
}
echo "</table>";
}
}elseif($_GET['p'] == 'all'){
$name = $_GET['p'];
echo "your name is $name";
}
}
else{
def();
}
?>
</body>
</html>
Did this file decode correctly?
Original Code
<?php
$config['db'] = array (
'host' => 'localhost',
'username' => 'root',
'password' => '',
'charset' => 'utf8',
'dbname' => 'database45'
);
$connection = new PDO('mysql:host=' . $config['db']['host'] . ';charset=' . $config['db']['charset'] . ';dbname=' . $config['db']['dbname'] , $config['db']['username'] , $config['db']['password'] );
?>
<?php
function def()
{?>
<a href="?p=except" class="btn btn-default" aria-label="Left Align"> </a>
<a href="?p=all" class="btn btn-default" aria-label="Left Align"> </a>
<?php } ?>
<html>
<head>
<meta charset="utf-8"/>
<title></title>
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css" integrity="sha384-BVYiiSIFeK1dGmJRAkycuHAHRg32OmUcww7on3RYdg4Va+PmSTsz/K68vbdEjh4u" crossorigin="anonymous">
<style>
body{
direction: rtl;
text-align: right;
}
</style>
</head>
<body>
<?php
if(isset($_GET['p'])){
if($_GET['p'] == 'except' ){
if(isset($_GET['userid'])){
$userid = $_GET['userid'];
$query = "SELECT * FROM tbl1 WHERE id = $userid ";
$stmt = $connection->prepare($query);
$stmt->bindColumn('id' , $id);
$stmt->bindColumn('nam' , $name);
$stmt->bindColumn('doreh' , $doreh);
$params = array( 1 , 1 );
$stmt->execute();
echo "<table border=\"1\">\n";
while($stmt->fetch()){
echo <<<EOS
$name $id $doreh .
EOS;
}
echo "</table>";
} else{
$query = "SELECT * FROM tbl1 WHERE 1";
$stmt = $connection->prepare($query);
$stmt->bindColumn('id' , $id);
$stmt->bindColumn('nam' , $name);
$stmt->bindColumn('doreh' , $doreh);
$params = array( 1 , 1 );
$stmt->execute();
echo "<table border=\"1\">\n";
while($stmt->fetch()){
echo <<<EOS
<tr>
<td>$id</td>
<td>$name</td>
<td>$doreh</td>
<td><a href='?p=except&userid=$id'></a></td>
</tr>
EOS;
}
echo "</table>";
}
}elseif($_GET['p'] == 'all'){
$name = $_GET['p'];
echo "your name is $name";
}
}
else{
def();
}
?>
</body>
</html>
Function Calls
| None |
Stats
| MD5 | 860aacefbbc34d8c39d22725c3e13d5d |
| Eval Count | 0 |
| Decode Time | 85 ms |