Fix padlist encoding, Add title to page

This commit is contained in:
otrs 2018-07-10 22:33:47 +02:00
parent a8a4a692fb
commit ffbe083f79

View File

@ -1,5 +1,13 @@
<h1>Read ALL the Pads</h1>
<h2>of the FS-Wiai Pad</h2>
<!DOCTYPE html>
<html>
<head>
<title>Pad List</title>
<meta charset="UTF-8">
</head>
<body>
<h1>Read ALL the Pads</h1>
<h2>of the FS-Wiai Pad</h2>
<?php
@ -8,6 +16,9 @@ $con = new mysqli("dbetherpad", "etherpad", "MyEtherpad17!", "etherpad");
if ($con->connect_errno){
die("FAIL");
}
$con->set_charset("utf8");
$query = 'select distinct substring(store.key,5,locate(":",store.key,5)-5) from store where store.key like "pad:%"';
$result = $con->query($query);
@ -15,8 +26,11 @@ $result = $con->query($query);
while($row = $result->fetch_row()){
echo "<a target='_blank' href='http://pad.wiai.de/p/".$row[0]."'>".$row[0]."</a><br/>";
echo "<a target='_blank' href='http://pad.wiai.de/p/".$row[0]."'>".$row[0]."</a><br/>\n";
}
?>
</body>
</html>