else { $msg=new LPC_I18n_message(); $msg->setAttr('language',$_SESSION['LPC_target_lang']); $msg->setAttr('message_key',$msgKey); } $ref=new LPC_I18n_reference($msgKey); if (!$ref->probe()) { $p->a("<div class='container'>← <a href='message_select.php'>Back to the message list</a></div>"); $p->a(new LPC_HTML_error("This reference message was not found in the database: [".htmlspecialchars($msgKey)."]")); $p->show(); return; $p->show(); } if (isset($_POST['delete'])) { $ref->delete(); header("Location: message_select.php"); exit; } $target_lang=new LPC_Language($_SESSION['LPC_target_lang']); $reference_lang=new LPC_Language($_SESSION['LPC_reference_lang']); if (isset($_POST['submit'])) { LPC_HTML_form::enforceSK(); $msg->setAttr('translation',$_POST['translation']); $msg->save(); $ref->setAttrs(array( 'comment'=>$_POST['comment'], 'system'=>isset($_POST['system']), )); $ref->save();