parent
7f35822090
commit
d28322e983
|
@ -34,7 +34,7 @@
|
|||
</style>
|
||||
</head>
|
||||
<body>
|
||||
<div><a href="index.php">View list</a> <a href="index.php?create=true">New note</a> | bbn</div>
|
||||
<div><a accesskey="l" href="index.php">View list</a> <a accesskey="n" href="index.php?create=true">New note</a> | bbn</div>
|
||||
<br>
|
||||
<?php
|
||||
if (isset($_POST['savebutton']))
|
||||
|
@ -47,7 +47,7 @@
|
|||
else if (isset($_POST['deletebutton']))
|
||||
{
|
||||
$title = $_POST['title'];
|
||||
unlink($dir . '/' . $title);
|
||||
rename($dir . '/' . $title, $dir . '/' . $title . '.del');
|
||||
}
|
||||
else if (isset($_GET['create']))
|
||||
{
|
||||
|
@ -64,13 +64,13 @@
|
|||
echo '<form action="index.php" method="POST">
|
||||
<div>
|
||||
<input name="title" value="' . $title . '">
|
||||
<!--<input type="submit" name="deletebutton" value="delete">-->
|
||||
</div>
|
||||
<br>
|
||||
<div>
|
||||
<textarea autofocus name="content" spellcheck="false">' . $content . '</textarea>
|
||||
</div>
|
||||
<input type="submit" name="savebutton" value="save" accesskey="s">
|
||||
<input accesskey="d" type="submit" name="deletebutton" value="delete">
|
||||
</form>';
|
||||
}
|
||||
else
|
||||
|
|
Loading…
Reference in New Issue