aboutsummaryrefslogtreecommitdiff
path: root/mod/messages/actions/send.php
diff options
context:
space:
mode:
authorcash <cash@36083f99-b078-4883-b0ff-0f9b5a30f544>2011-01-15 22:28:46 +0000
committercash <cash@36083f99-b078-4883-b0ff-0f9b5a30f544>2011-01-15 22:28:46 +0000
commit43c33492d2ab65a783c17559cf8dabd7832e9ea1 (patch)
tree7107fed1b5424db1405b842972c7e4c47f11bfd3 /mod/messages/actions/send.php
parente8d148970261207efbe5435e1abcf68c5ed59cc8 (diff)
downloadelgg-43c33492d2ab65a783c17559cf8dabd7832e9ea1.tar.gz
elgg-43c33492d2ab65a783c17559cf8dabd7832e9ea1.tar.bz2
Updated the messages plugin to use the new CSS/HTML
git-svn-id: http://code.elgg.org/elgg/trunk@7886 36083f99-b078-4883-b0ff-0f9b5a30f544
Diffstat (limited to 'mod/messages/actions/send.php')
-rw-r--r--mod/messages/actions/send.php57
1 files changed, 0 insertions, 57 deletions
diff --git a/mod/messages/actions/send.php b/mod/messages/actions/send.php
deleted file mode 100644
index 59d90a9d2..000000000
--- a/mod/messages/actions/send.php
+++ /dev/null
@@ -1,57 +0,0 @@
-<?php
-/**
-* Elgg send a message action page
-*
-* @package ElggMessages
-*/
-
-// Make sure we're logged in (send us to the front page if not)
-if (!isloggedin()) forward();
-
-// Get input data
-$title = strip_tags(get_input('title')); // message title
-$message_contents = get_input('message'); // the message
-$send_to = get_input('send_to'); // this is the user guid to whom the message is going to be sent
-$reply = get_input('reply',0); // this is the guid of the message replying to
-
-// Cache to the session to make form sticky
-$_SESSION['msg_to'] = $send_to;
-$_SESSION['msg_title'] = $title;
-$_SESSION['msg_contents'] = $message_contents;
-
-if (empty($send_to)) {
- register_error(elgg_echo("messages:user:blank"));
- forward("mod/messages/send.php");
-}
-
-$user = get_user($send_to);
-if (!$user) {
- register_error(elgg_echo("messages:user:nonexist"));
- forward("mod/messages/send.php");
-}
-
-// Make sure the message field, send to field and title are not blank
-if (empty($message_contents) || empty($title)) {
- register_error(elgg_echo("messages:blank"));
- forward("mod/messages/send.php");
-}
-
-// Otherwise, 'send' the message
-$result = messages_send($title,$message_contents,$send_to,0,$reply);
-
-// Save 'send' the message
-if (!$result) {
- register_error(elgg_echo("messages:error"));
- forward("mod/messages/send.php");
-}
-
-// successful so uncache form values
-unset($_SESSION['msg_to']);
-unset($_SESSION['msg_title']);
-unset($_SESSION['msg_contents']);
-
-// Success message
-system_message(elgg_echo("messages:posted"));
-
-// Forward to the users inbox
-forward('mod/messages/sent.php');