|
|
|
@ -44,7 +44,7 @@
|
|
|
|
|
exit;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
echo '<div><a accesskey="h" href="/">home</a></div><br>';
|
|
|
|
|
echo '<div><a accesskey="h" href="' . $root . '">home</a></div><br>';
|
|
|
|
|
|
|
|
|
|
if (isset($_POST['savebutton']))
|
|
|
|
|
{
|
|
|
|
@ -90,10 +90,16 @@
|
|
|
|
|
}
|
|
|
|
|
else
|
|
|
|
|
{
|
|
|
|
|
$defaulttitle = date("Y-m-d H.i.s", time());
|
|
|
|
|
if (isset($_GET['userdata']))
|
|
|
|
|
{
|
|
|
|
|
$defaulttitle = $_GET['userdata'];
|
|
|
|
|
}
|
|
|
|
|
echo '<form action="index.php" method="GET">
|
|
|
|
|
<input list="notes" name="userdata" value="' . date("Y-m-d H.i.s", time()) . '">
|
|
|
|
|
<input list="notes" name="userdata" value="' . $defaulttitle . '">
|
|
|
|
|
<input accesskey="n" type="submit" name="openaction" value="open">
|
|
|
|
|
<input accesskey="f" type="submit" name="filteraction" value="filter">
|
|
|
|
|
<input accesskey="g" type="submit" name="searchaction" value="search">
|
|
|
|
|
</form>';
|
|
|
|
|
echo '<br>';
|
|
|
|
|
|
|
|
|
@ -109,6 +115,14 @@
|
|
|
|
|
if (!str_ends_with($name, '.del')
|
|
|
|
|
&& (!isset($_GET['filteraction']) || str_contains($name, $_GET['userdata'])))
|
|
|
|
|
{
|
|
|
|
|
if (isset($_GET['searchaction']))
|
|
|
|
|
{
|
|
|
|
|
$content = file_get_contents($path);
|
|
|
|
|
if (!str_contains($content, $_GET['userdata']))
|
|
|
|
|
{
|
|
|
|
|
continue;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
echo '<div><a href=index.php?openaction&userdata=' . urlencode($name) . '>' . $name .'</a></div>';
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|