git.shiar.nl
/
minimedit.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
foto: replace deprecated <strike> element by <s>
[minimedit.git]
/
widget
/
reply.php
diff --git
a/widget/reply.php
b/widget/reply.php
index cedcc4919699194fe60926bf5a67adf316dfa38c..3984349d82c646a6928fbd6d56efc03984e06569 100644
(file)
--- a/
widget/reply.php
+++ b/
widget/reply.php
@@
-10,14
+10,15
@@
if ($_POST) {
require_once 'upload.inc.php';
try {
$html = messagehtml($_POST['reply']);
require_once 'upload.inc.php';
try {
$html = messagehtml($_POST['reply']);
- if ($_FILES and
isset
($_FILES['image'])) {
+ if ($_FILES and
!empty
($_FILES['image'])) {
$target = 'data/upload';
if (!file_exists($target)) {
throw new Exception("er is geen uploadmap aanwezig op $target");
}
$target .= '/' . $User->login;
$target = 'data/upload';
if (!file_exists($target)) {
throw new Exception("er is geen uploadmap aanwezig op $target");
}
$target .= '/' . $User->login;
- $result = userupload($_FILES['image'], $target);
- $html .= sprintf('<p><img src="/thumb/640x/%s" /></p>', $result);
+ if ($result = userupload($_FILES['image'], $target)) {
+ $html .= sprintf('<p><img src="/thumb/640x/%s" /></p>', $result);
+ }
}
$query = $Db->set('comments', [
'page' => $Page,
}
$query = $Db->set('comments', [
'page' => $Page,
@@
-89,7
+90,7
@@
while ($row = $query->fetch()) {
printf("<em>%s</em> %s",
$journalcol[$change->col], sprintf(
!isset($change->old_value) ? 'gewijzigd naar <q>%2$s</q>' :
printf("<em>%s</em> %s",
$journalcol[$change->col], sprintf(
!isset($change->old_value) ? 'gewijzigd naar <q>%2$s</q>' :
- (!isset($change->value) ? 'verwijderd (<s
trike>%s</strike
>)' :
+ (!isset($change->value) ? 'verwijderd (<s
>%s</s
>)' :
'gewijzigd van <q>%s</q> naar <q>%s</q>'),
$change->old_value, $change->value
)
'gewijzigd van <q>%s</q> naar <q>%s</q>'),
$change->old_value, $change->value
)
@@
-102,7
+103,7
@@
while ($row = $query->fetch()) {
print "</li>\n";
}
print "</li>\n";
}
-if ($User) {
+if ($User
->login
) {
print '<li>';
print '<form method="post" action="" enctype="multipart/form-data">';
if (isset($Issue) and $User->admin("edit $Page")) {
print '<li>';
print '<form method="post" action="" enctype="multipart/form-data">';
if (isset($Issue) and $User->admin("edit $Page")) {