www.gusucode.com > Tatter Tools 0.961 SE GB2312 简体中文版 > upload/sync_view.php
<? include("inc_global.php"); include("inc_function.php"); // header("Content-Type: text/xml"); $rss .= "<?xml version=\"1.0\" encoding=\"gb2312\" ?>\r\n"; $rss .= "<response>\r\n"; $sql = " select no, category1, category2, title, body, local_info, user_id, image_file_path1, image_file_path2, regdate from t3_".$dbid." where no = $pl and is_public = '1' and is_sync = '1' "; list ($no, $category1, $category2, $title, $body, $local_info, $user_id, $image_file_path1, $image_file_path2, $regdate) = @mysql_fetch_array(@mysql_query($sql)); if (!$no) { print $rss; ?> <error>1</error><message>error!!</message></response> <? exit; } $category = htmlspecialchars(get_category1_label($category1)." - ".get_category2_label($category2)); $p_title = htmlspecialchars($p_title); $title = htmlspecialchars($title); $link = htmlspecialchars($s_root_path."index.php?pl=$no"); $description = str_innerHTML(htmlspecialchars(str_tag_truncate(nl2brc(attach_image(1,$body, $s_root_path, $r_root_path, $attach_path.$image_file_path1.$image_file_path2))))); $creator = htmlspecialchars($p_user_id); $rss .= "<item>\r\n"; $rss .= "<site>$p_title</site>\r\n"; $rss .= "<sitelink>".$s_root_path."index.php</sitelink>\r\n"; $rss .= "<title>$title</title>\r\n"; $rss .= "<link>$link</link>\r\n"; $rss .= "<description>$description</description>\r\n"; $rss .= "<subject>$category</subject>\r\n"; $rss .= "<creator>$p_user_nick</creator>\r\n"; $rss .= "<local>$local_info</local>\r\n"; $rss .= "<date>$regdate</date>\r\n"; $rss .= "</item>\r\n"; $rss .= "</response>\r\n"; print $rss; ?>