Ejemplo n.º 1
0
         }
     } else {
         // post in selected groups
         foreach ($_POST['route_targets_album'] as $aid) {
             //only send to selected albums
             $res = save_post(NULL, $aid, TRUE);
             if ($res['msg']) {
                 $succ_msg = $res['msg'];
             }
             add_tags_to_content($res['content_id'], $tag_string);
         }
     }
 }
 if (!empty($created_album_id)) {
     // add the content to created album
     $res = save_post(NULL, $created_album_id, TRUE);
     if ($res['msg']) {
         $succ_msg = $res['msg'];
     }
     add_tags_to_content($res['content_id'], $tag_string);
 }
 route_to_outputthis($permalink_title, $permalink_body);
 //redirect to group if user has come from group's page
 //redirect to permalink
 if ($_GET['ccid']) {
     $loc = $base_url . '/group.php?gid=' . $_GET['ccid'] . $save_res;
 } else {
     $msg = "&err=" . urlencode(MessagesHandler::get_message($succ_msg));
     $loc = $base_url . '/content.php?cid=' . $permalink_cid . $msg;
 }
 header("location:{$loc}");
Ejemplo n.º 2
0
// You can get copies of the licenses here:
// 		http://www.affero.org/oagpl.html
// AFFERO GENERAL PUBLIC LICENSE is also included in the file called "COPYING".
if (!defined('mnmpath')) {
    include '../config.php';
    include mnminclude . 'html1.php';
}
array_push($globals['cache-control'], 'no-cache');
http_cache();
$message = new PrivateMessage();
if (!empty($_POST['author'])) {
    $message_id = intval($_REQUEST['id']);
    if ($message_id > 0) {
        save_post($message_id);
    } else {
        save_post(0);
    }
} else {
    if (!empty($_REQUEST['id'])) {
        if ($message = PrivateMessage::from_db(intval($_REQUEST['id']))) {
            $message->print_edit_form();
        }
    } else {
        // A new post
        $message = new PrivateMessage();
        if (!empty($_REQUEST['user_id'])) {
            $message->to = intval($_REQUEST['user_id']);
        }
        $message->author = $current_user->user_id;
        $message->print_edit_form();
    }
Ejemplo n.º 3
0
    save_post(2);
} elseif ($_POST["Digits"] == "3") {
    ?>
    <Say language="ja-jp">緑町を選択しました。</Say>
<?php 
    save_post(3);
} elseif ($_POST["Digits"] == "4") {
    ?>
    <Say language="ja-jp">材木町を選択しました。</Say>
<?php 
    save_post(4);
} elseif ($_POST["Digits"] == "5") {
    ?>
    <Say language="ja-jp">城西町を選択しました。</Say>
<?php 
    save_post(5);
} else {
    ?>
    <Say language="ja-jp">入力は1から5までです。</Say>
<?php 
}
?>

<!--
-  報告された番号をその場でPOST_URLへPOSTで送信
-->
<?php 
function save_post($num)
{
    $url = 'POST_URL';
    $data = array('number' => $num);