123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126 |
- <?php
- if(!defined('entry')) define('entry',true);
-
- ?>
- <?php
- header("Content-type: text/xml; charset=utf-8");
-
- require(dirname(__FILE__)."/config.php");
- include("classes/configuration.class.php");
- include("classes/gelato.class.php");
- include("classes/textile.class.php");
- $isFeed = true;
- $tumble = new gelato();
- $conf = new configuration();
-
- echo "<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n";
- ?>
- <gelato version="1.0">
- <?php
-
- if (isset($_GET["action"]) && $_GET["action"] == "read") {
- if (isset($_GET["start"])) { $start = $_GET["start"]; } else { $start = 0; }
- if (isset($_GET["num"])) { $num = $_GET["num"]; } else { $num = 20; }
- if (isset($_GET["type"])) { $type = $_GET["type"]; } else { $type = null; }
- if ($num > 50) { $num = 50; }
- ?>
- <tumblelog name="<?php echo $_SESSION["user_login"];?>" timezone="<?php echo $conf->offsetCity;?>" title="<?php echo $conf->title;?>"><?php echo $conf->description;?></tumblelog>
-
- <?php
- switch ($type) {
- case "post":
- $_GET["type"] = "1";
- break;
- case "photo":
- $_GET["type"] = "2";
- break;
- case "quote":
- $_GET["type"] = "3";
- break;
- case "url":
- $_GET["type"] = "4";
- break;
- case "conversation":
- $_GET["type"] = "5";
- break;
- case "video":
- $_GET["type"] = "6";
- break;
- case "mp3":
- $_GET["type"] = "7";
- break;
- }
- $rs = $tumble->getPosts($num, $start);
- if ($tumble->contarRegistros()>0) {
- ?>
- <posts start="<?php echo $start; ?>" total="<?php echo $num; ?>">
- <?php
- ?>
- </posts>
- <?php
- }
- }
- ?>
- </gelato>
|