summaryrefslogtreecommitdiff
path: root/includes/pages/admin_news.php
diff options
context:
space:
mode:
authorPhilip Häusler <msquare@notrademark.de>2013-09-18 01:38:36 +0200
committerPhilip Häusler <msquare@notrademark.de>2013-09-18 01:38:36 +0200
commitbfb0cacd541cc20129a3c0ac77130370741dca18 (patch)
tree0a0e86e1a53d712065664c12d06603bc044df9ec /includes/pages/admin_news.php
parentd50cc21f50cb3ec3afdabb74a20d81bd1a53dfbd (diff)
mysql to mysqli and a lot of cleanup and mvc
Diffstat (limited to 'includes/pages/admin_news.php')
-rw-r--r--includes/pages/admin_news.php6
1 files changed, 5 insertions, 1 deletions
diff --git a/includes/pages/admin_news.php b/includes/pages/admin_news.php
index 661aa511..25807151 100644
--- a/includes/pages/admin_news.php
+++ b/includes/pages/admin_news.php
@@ -17,6 +17,10 @@ function admin_news() {
if (count($news) > 0) {
list ($news) = $news;
+ $user_source = User($news['UID']);
+ if($user_source === false)
+ engelsystem_error("Unable to load user.");
+
$html .= '<a href="' . page_link_to("news") . '">&laquo Back</a>';
$html .= "<form action=\"" . page_link_to("admin_news") . "&action=save\" method=\"post\">\n";
@@ -29,7 +33,7 @@ function admin_news() {
$html .= " <tr><td>Text</td><td><textarea rows=\"10\" cols=\"80\" name=\"eText\">" .
$news["Text"] . "</textarea></td></tr>\n";
$html .= " <tr><td>Engel</td><td>" .
- UID2Nick($news["UID"]) . "</td></tr>\n";
+ User_Nick_render($user_source) . "</td></tr>\n";
$html .= " <tr><td>Treffen</td><td>" . html_select_key('eTreffen', 'eTreffen', array (
'1' => "Ja",
'0' => "Nein"