<?php
//Copyright (c) Florian Grannemann
//Last change in version: 2.1 Alpha 2
/*
******************************************************************************
ADbNewsSender 2
Copyright (C) 2009 Florian Grannemann (hide@address.com)
Website: http://adbnewssender.sf.net
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 3 of the License, or
any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program. If not, see http://www.gnu.org/licenses/
******************************************************************************
*/
//Do not edit anything unless you realy REALY know what you are doing!
//Using the default $_REQUEST[] to avoid problems caused by including the request handler
//sending header:
if($_REQUEST["DraftType"]=="html")
{
header('Content-type:text/html');
}
else
{
header('Content-type:text/plain');
}
//to avoid problems on some servers:
//if that makes problems, use
//$path_to_protected=".."; instead
//But this should work on all UNIX-like systems:
$path_to_protected=dirname(__FILE__)."/..";
include "$path_to_protected/skeleton/public_apis.class.php.inc";
include "$path_to_protected/skeleton/private_apis.class.php.inc";
$path_to_db_conf="$path_to_protected/database/DBconf.php.inc";
$path_to_db_defs="$path_to_protected/skeleton/includes/db_defs";
$MyDB = new ADBNS_DB($path_to_db_defs,$path_to_db_conf);
$draftARR=array();
$MyDrafts=new ADBNS_Drafts(intval($_REQUEST["NLID"]),$MyDB);
$draftARR=$MyDrafts->get_draft_data(intval($_REQUEST["DraftID"]));
print html_entity_decode($draftARR["message"]);
?>