@ 2014-05-30T20:14:16Z <?php
ini_set('display_errors', 'On');
error_reporting(E_ALL);
$time = microtime();
$time = explode(' ', $time);
$time = $time[1] + $time[0];
$start = $time;
define("DB_HOST","mysql117.loopia.se");
define("DB_USER","normal@i103189");
define("DB_PASS","KungMicke87");
define("DB_NAME","indiehjaerta_com");
?>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html;charset=UTF-8" />
<title>indiehjaerta.com - Forum</title>
<link href="style_test.css" rel="stylesheet" type="text/css" />
</head>
<body>
<a href="login.php">Login<a/> -
<a href="admin.php">Admin<a/> -
<a href="members.php">Members<a/> -
<a href="register.php">Register<a/> -
<a href="blog.php">Blog<a/> -
<a href="news.php">News<a/> -
<a href="event.php">Event<a/> -
<a href="forum.php">Forum<a/> -
<a href="profile.php">Profile<a/> -
<a href="logout.php">Logout<a/>
<br /> <br />
<!-- New Post Start -->
<!-- New Post End -->
<!-- List Forum Category Threads - Start -->
<?php
if (isset($_GET['fid']))
{
if (isset($_GET['tid']))
{
// Connect to MySQLi
$sqli = mysqli_connect(DB_HOST, DB_USER, DB_PASS, DB_NAME) or die("Error: ".mysqli_error($sqli));
// Check connection
if (mysqli_connect_errno())
{
echo "Failed to connect to MySQL: " . mysqli_connect_error();
}
$tid = $_GET['tid'];
$query = mysqli_query($sqli, "SELECT * FROM forumtopics WHERE id='$tid'") or die("Error: ".mysqli_error($sqli));
$checkthreadexists = mysqli_num_rows($query);
// Check if we have ny threads in this category
if($checkthreadexists == 0)
{
// No threads
echo '<span class="text">No such topic ID exists!</span><br />';
}
else
{
$row = mysqli_fetch_array($query);
$uid = $row['userid'];
$userquery = mysqli_query($sqli, "SELECT * FROM members WHERE id='$uid'") or die("Error: ".mysqli_error($sqli));
$userrow = mysqli_fetch_array($userquery);
echo '<table border="0">';
echo '<tr> ';
echo '<th></th>';
echo '<th></th>';
echo '<th><span class="text"><span class="text">' .$row['threadname']. '</span></th>';
echo '<th></th>';
echo '</tr>';
echo '<tr>';
echo '<td><a href="profile.php?id=' .$uid. '"><span class="text">' .$userrow['username']. '</span></a></td>';
echo '<td></td>';
echo '<td><span class="text">' .$row['text']. '</span></td>';
echo '<td></td>';
echo '</tr>';
echo '</table><br />';
}
}
else
{
// Connect to MySQLi
$sqli = mysqli_connect(DB_HOST, DB_USER, DB_PASS, DB_NAME) or die("Error: ".mysqli_error($sqli));
// Check connection
if (mysqli_connect_errno())
{
echo "Failed to connect to MySQL: " . mysqli_connect_error();
}
$fid = $_GET['fid'];
$query = mysqli_query($sqli, "SELECT * FROM forumtopics WHERE categoryid='$fid' ORDER BY id") or die("Error: ".mysqli_error($sqli)); //Don't order by ID!
$checknumthreads = mysqli_num_rows($query);
// Check if we have ny threads in this category
if($checknumthreads == 0)
{
// No threads
echo '<span class="text">No forums threads found in the database!</span><br />';
}
else
{
echo '<table border="0">
<tr>
<th><span class="text">Name</span></th>
<th></th>
<th><span class="text">Replies</span></th>
<th></th>
</tr>';
while ($row = mysqli_fetch_array($query))
{
echo '<tr>';
echo '<td><a href="?fid=' .$_GET['fid']. '&tid=' .$row['id']. '"><span class="text">' .$row['threadname']. '</span></a></td>';
echo '<td></td>';
echo '<td><span class="text">0</span></td>';
echo '<td></td>';
echo '</tr>';
}
echo '</table><br />';
}
}
?>
<!-- List Forum Category Threads - End -->
<!-- List Forum Categories - Start -->
<?php
}
else
{
// Connect to MySQLi
$sqli = mysqli_connect(DB_HOST, DB_USER, DB_PASS, DB_NAME) or die("Error: ".mysqli_error($sqli));
// Check connection
if (mysqli_connect_errno())
{
echo "Failed to connect to MySQL: " . mysqli_connect_error();
}
$query = mysqli_query($sqli, "SELECT * FROM forumcat ORDER BY id") or die("Error: ".mysqli_error($sqli));
$checknumforums = mysqli_num_rows($query);
// Check if we have any forum categories
if($checknumforums == 0)
{
// No forums
echo '<span class="text">No forums found in the database!</span><br />';
}
else
{
?>
<table width="300" border="0" align="center" cellpadding="0" cellspacing="1" bgcolor="#CCCCCC">
<tr>
<td>
<strong>Forums</strong>
</td>
</tr>
<tr>
<td>
<table width="100%" border="0" cellpadding="4" cellspacing="1" bgcolor="#FFFFFF">
<tr>
<td><strong>Name</strong></td>
<td></td>
<td><strong>Threads</strong></td>
<td><strong>Last Post</strong></td>
</tr>
<?php
while ($row = mysqli_fetch_array($query))
{
?>
<tr>
<td><a href="?fid=<?php echo $row['id'] ?>" style="color: black"><?php echo $row['forumname'] ?></a></td>
<td></td>
<td>0</td>
<td></td>
</tr>
<?php
}
?>
</table>
</td>
</tr>
</table>
<?php
}
?>
<!-- List Forum Categories - End -->
<?php
$time = microtime();
$time = explode(' ', $time);
$time = $time[1] + $time[0];
$finish = $time;
$total_time = round(($finish - $start), 4);
echo '<span class="text">Page generated in '.$total_time.' seconds.</span><br />';
?>
</body>
</html>
Enable javascript to submit You have javascript disabled. You will not be able to edit any code.
Here you find the average performance (time & memory) of each version. A grayed out version indicates it didn't complete successfully (based on exit-code).
Version System time (s) User time (s) Memory (MiB) 5.4.29 0.008 0.044 12.51 5.4.28 0.005 0.043 12.41 5.4.27 0.010 0.043 12.41 5.4.26 0.009 0.036 12.41 5.4.25 0.010 0.047 12.41 5.4.24 0.009 0.037 12.41 5.4.23 0.007 0.048 12.40 5.4.22 0.007 0.051 12.40 5.4.21 0.009 0.047 12.40 5.4.20 0.010 0.049 12.40 5.4.19 0.006 0.045 12.39 5.4.18 0.007 0.042 12.40 5.4.17 0.005 0.045 12.41 5.4.16 0.009 0.047 12.40 5.4.15 0.007 0.043 12.40 5.4.14 0.009 0.041 12.09 5.4.13 0.009 0.044 12.07 5.4.12 0.011 0.057 12.04 5.4.11 0.008 0.040 12.03 5.4.10 0.008 0.054 12.03 5.4.9 0.009 0.045 12.03 5.4.8 0.008 0.043 12.03 5.4.7 0.009 0.049 12.02 5.4.6 0.008 0.047 12.03 5.4.5 0.009 0.045 12.03 5.4.4 0.007 0.039 12.01 5.4.3 0.010 0.043 12.01 5.4.2 0.006 0.038 12.01 5.4.1 0.008 0.035 12.01 5.4.0 0.006 0.049 11.50 5.3.28 0.008 0.043 12.71 5.3.27 0.007 0.042 12.72 5.3.26 0.007 0.047 12.72 5.3.25 0.010 0.041 12.72 5.3.24 0.009 0.047 12.72 5.3.23 0.011 0.041 12.71 5.3.22 0.009 0.048 12.68 5.3.21 0.010 0.038 12.68 5.3.20 0.006 0.045 12.68 5.3.19 0.009 0.046 12.68 5.3.18 0.006 0.038 12.67 5.3.17 0.009 0.035 12.67 5.3.16 0.007 0.039 12.67 5.3.15 0.008 0.041 12.67 5.3.14 0.008 0.036 12.66 5.3.13 0.009 0.039 12.66 5.3.12 0.008 0.044 12.66 5.3.11 0.009 0.046 12.66 5.3.10 0.016 0.049 12.13 5.3.9 0.008 0.044 12.11 5.3.8 0.009 0.049 12.10 5.3.7 0.010 0.044 12.10 5.3.6 0.007 0.051 12.09 5.3.5 0.009 0.046 12.03 5.3.4 0.007 0.050 12.04 5.3.3 0.007 0.045 11.99 5.3.2 0.007 0.036 11.78 5.3.1 0.007 0.038 11.74 5.3.0 0.007 0.039 11.72 5.2.17 0.004 0.036 9.23 5.2.16 0.008 0.031 9.23 5.2.15 0.006 0.034 9.23 5.2.14 0.006 0.038 9.22 5.2.13 0.003 0.038 9.19 5.2.12 0.007 0.034 9.18 5.2.11 0.004 0.036 9.20 5.2.10 0.007 0.029 9.19 5.2.9 0.007 0.030 9.19 5.2.8 0.005 0.039 9.19 5.2.7 0.009 0.039 9.19 5.2.6 0.007 0.039 9.14 5.2.5 0.004 0.032 9.11 5.2.4 0.005 0.031 9.09 5.2.3 0.004 0.034 9.07 5.2.2 0.004 0.034 9.06 5.2.1 0.005 0.030 8.98 5.2.0 0.004 0.034 8.83 5.1.6 0.005 0.028 8.13 5.1.5 0.003 0.029 8.12 5.1.4 0.004 0.028 8.10 5.1.3 0.006 0.030 8.46 5.1.2 0.007 0.030 8.48 5.1.1 0.007 0.026 8.20 5.1.0 0.004 0.026 8.20 5.0.5 0.004 0.024 6.69 5.0.4 0.005 0.019 6.55 5.0.3 0.003 0.033 6.36 5.0.2 0.005 0.023 6.33 5.0.1 0.004 0.025 6.31 5.0.0 0.005 0.032 6.31 4.4.9 0.003 0.018 4.78 4.4.8 0.009 0.016 4.76 4.4.7 0.008 0.024 4.75 4.4.6 0.004 0.023 4.76 4.4.5 0.005 0.021 4.77 4.4.4 0.005 0.031 4.71 4.4.3 0.004 0.027 4.76 4.4.2 0.002 0.029 4.85 4.4.1 0.003 0.018 4.85 4.4.0 0.004 0.027 4.76 4.3.11 0.003 0.019 4.67 4.3.10 0.002 0.015 4.66 4.3.9 0.004 0.019 4.63 4.3.8 0.002 0.025 4.59 4.3.7 0.003 0.020 4.63 4.3.6 0.004 0.015 4.63 4.3.5 0.005 0.017 4.63 4.3.4 0.004 0.031 4.54 4.3.3 0.002 0.018 3.35 4.3.2 0.004 0.016 3.33 4.3.1 0.002 0.026 3.28 4.3.0 0.013 0.023 8.10
preferences:dark mode live preview
142.09 ms | 1394 KiB | 7 Q