edit.php (936B)
1 <div class="container"> 2 <h1>NoteController/edit/:note_id</h1> 3 4 <div class="box"> 5 <h2>Edit a note</h2> 6 7 <!-- echo out the system feedback (error and success messages) --> 8 <?php $this->renderFeedbackMessages(); ?> 9 10 <?php if ($this->note) { ?> 11 <form method="post" action="<?php echo Config::get('URL'); ?>/note/editSave"> 12 <label>Change text of note: </label> 13 <!-- we use htmlentities() here to prevent user input with " etc. break the HTML --> 14 <input type="hidden" name="note_id" value="<?php echo htmlentities($this->note->note_id); ?>" /> 15 <input type="text" name="note_text" value="<?php echo htmlentities($this->note->note_text); ?>" /> 16 <input type="submit" value='Change' /> 17 </form> 18 <?php } else { ?> 19 <p>This note does not exist.</p> 20 <?php } ?> 21 </div> 22 </div>