Source for file tb.php
Documentation is available at tb.php
* MvBlog -- An open source no-nosense blogtool
* Copyright (C) 2005-2007, Michiel van Baak
* Michiel van Baak <mvanbaak@users.sourceforge.net>
* See http://www.mvblog.org for more information on MvBlog.
* That page also provides Bugtrackers, Filereleases etc.
* This program is free software, distributed under the terms of
* the GNU General Public License Version 2. See the LICENSE file
* at the top of the source tree.
* @author Michiel van Baak
* @copyright 2005-2007 Michiel van Baak
header("Content-Type: text/xml; charset=UTF-8");
echo
"<?xml version=\"1.0\" encoding=\"utf-8\"?".
">\n";
echo
"<error>1</error>\n";
echo
"<message>$errorstr</message>\n";
echo
"<?xml version=\"1.0\" encoding=\"utf-8\"?".
">\n";
echo
"<error>0</error>\n";
/* check to see if this article is here */
$sql =
sprintf("SELECT COUNT(*) AS count FROM articles WHERE active = 1 AND public = 1 AND id = %d", $tb_id);
$res =
& $mvblog->db->query($sql);
$row =
$res->fetchRow(MDB2_FETCHMODE_ASSOC);
$title =
$_POST["title"];
$excerpt =
$_POST["excerpt"];
$blog_name =
$_POST["blog_name"];
$charset =
$_POST["charset"];
if (empty($title) &&
empty($tb_url) &&
empty($blog_name)) {
$sql =
sprintf("INSERT INTO comments (name, website, email, comment, date, articles_id, title) VALUES ('%s', '%s', '%s', '%s', %d, %d, '%s'",
$res =
& $mvblog->db->exec($sql);
if (PEAR::isError($res)) {
tb_response(1, "Something went wrong with inserting your trackback in the comments system. error:".
$res->getMessage());
Documentation generated on Fri, 28 Dec 2007 13:17:42 +0100 by phpDocumentor 1.4.1