Exemplo n.º 1
0
$data = parse($mimedecoder->get_parsed_message()->parts['0']->body, true);


if($data['password'] == $bloggy_config['mail_pass']) {
//If the passwords match, lets continue!
$data['password'] = null;

$data = array_filter($data);

$post = "";

foreach($data as $key => $value) {
$post .= $key.": ".$value."\r\n";
}

$dirlistnormal = getDirectoryList('./posts');

$post_number = count($dirlistnormal) + 1;

$post_name = "./posts/post".$post_number.".post";

$file_stream = fopen($post_name, 'w');
fwrite($file_stream, $post);

}

$response=$imap->delete_message(1);

}
//header('Location: index.php')
?>