various cleans up, fix a few content types for safari, add headers to all files

orig_fof
steveminutillo 2007-06-29 03:19:23 +00:00
parent f052ca8f45
commit ad8833a08a
16 changed files with 74 additions and 21 deletions

View File

@ -2,7 +2,7 @@
/*
* This file is part of FEED ON FEEDS - http://feedonfeeds.com/
*
* add.php - displays form to add a feed
* add-single.php - adds a single feed
*
*
* Copyright (C) 2004-2007 Stephen Minutillo

View File

@ -2,7 +2,7 @@
/*
* This file is part of FEED ON FEEDS - http://feedonfeeds.com/
*
* add.php - displays form to add a feed
* add-tag.php - adds (or removes) a tag to an item
*
*
* Copyright (C) 2004-2007 Stephen Minutillo
@ -11,9 +11,6 @@
* Distributed under the GPL - see LICENSE
*
*/
ob_start("ob_gzhandler");
header("Content-Type: text/plain; charset=utf-8");
include_once("fof-main.php");
@ -25,11 +22,11 @@ foreach(explode(" ", $tags) as $tag)
{
if($remove == 'true')
{
fof_untag_item(fof_current_user(), $item, $tag);
fof_untag_item(fof_current_user(), $item, $tag);
}
else
{
fof_tag_item(fof_current_user(), $item, $tag);
fof_tag_item(fof_current_user(), $item, $tag);
}
}
?>

View File

@ -1,4 +1,16 @@
<?php
/*
* This file is part of FEED ON FEEDS - http://feedonfeeds.com/
*
* favicon.php - displays an image cached by SimplePie
*
*
* Copyright (C) 2004-2007 Stephen Minutillo
* steve@minutillo.com - http://minutillo.com/steve/
*
* Distributed under the GPL - see LICENSE
*
*/
require_once('simplepie/simplepie.inc');
SimplePie_Misc::display_cached_file($_GET['i'], './cache', 'spi');
?>

View File

@ -2,7 +2,7 @@
/*
* This file is part of FEED ON FEEDS - http://feedonfeeds.com/
*
* init.php - (nearly) all of the DB specific code
* fof-db.php - (nearly) all of the DB specific code
*
*
* Copyright (C) 2004-2007 Stephen Minutillo

View File

@ -38,6 +38,16 @@ if(!$fof_no_login)
require_once('simplepie/simplepie.inc');
function fof_set_content_type()
{
static $set;
if(!$set)
{
header("Content-Type: text/html; charset=utf-8");
$set = true;
}
}
function fof_log($message)
{
global $LOG;

View File

@ -1,4 +1,16 @@
<?php
/*
* This file is part of FEED ON FEEDS - http://feedonfeeds.com/
*
* fof-render.php - contains function used to render a single item
*
*
* Copyright (C) 2004-2007 Stephen Minutillo
* steve@minutillo.com - http://minutillo.com/steve/
*
* Distributed under the GPL - see LICENSE
*
*/
// From Brian Suda @ http://suda.co.uk/projects/SEHL/

View File

@ -14,7 +14,7 @@
include_once("fof-main.php");
header("Content-Type: text/html; charset=utf-8");
fof_set_content_type();
if(isset($_COOKIE['fof_sidebar_width']))
{

View File

@ -15,7 +15,8 @@
$fof_no_login = true;
include_once("fof-main.php");
header("Content-Type: text/html; charset=utf-8");
fof_set_content_type();
// compatibility testing code lifted from SimplePie

View File

@ -1,9 +1,21 @@
<?php
/*
* This file is part of FEED ON FEEDS - http://feedonfeeds.com/
*
* item.php - renders a single item (useful for Ajax)
*
*
* Copyright (C) 2004-2007 Stephen Minutillo
* steve@minutillo.com - http://minutillo.com/steve/
*
* Distributed under the GPL - see LICENSE
*
*/
include_once("fof-main.php");
include_once("fof-render.php");
header("Content-Type: text/html; charset=utf-8");
fof_set_content_type();
$row = fof_get_item(fof_current_user(), $_GET['id']);

View File

@ -1,4 +1,16 @@
<?php
/*
* This file is part of FEED ON FEEDS - http://feedonfeeds.com/
*
* items.php - displays right hand side "frame"
*
*
* Copyright (C) 2004-2007 Stephen Minutillo
* steve@minutillo.com - http://minutillo.com/steve/
*
* Distributed under the GPL - see LICENSE
*
*/
include_once("fof-main.php");
include_once("fof-render.php");

View File

@ -17,7 +17,8 @@ ob_start();
$fof_no_login = true;
include_once("fof-main.php");
header("Content-Type: text/html; charset=utf-8");
fof_set_content_type();
if(isset($_POST["user_name"]) && isset($_POST["user_password"]))
{

View File

@ -14,7 +14,6 @@
ob_start();
include_once("fof-main.php");
header("Content-Type: text/html; charset=utf-8");
fof_logout();

View File

@ -14,6 +14,8 @@
include_once("fof-main.php");
fof_set_content_type();
?>
<img id="throbber" src="image/throbber.gif" align="left" style="position: fixed; left: 0; top: 0; display: none">
@ -299,7 +301,3 @@ if(!isset($direction))
?>

View File

@ -13,7 +13,8 @@
*/
include_once("fof-main.php");
header("Content-Type: text/html; charset=utf-8");
fof_set_content_type();
?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

View File

@ -2,7 +2,7 @@
/*
* This file is part of FEED ON FEEDS - http://feedonfeeds.com/
*
* update.php - updates feeds with feedback
* update-single.php - updates a single feed
*
*
* Copyright (C) 2004-2007 Stephen Minutillo

View File

@ -14,8 +14,6 @@
include_once("fof-main.php");
header("Content-Type: text/html; charset=utf-8");
while (list ($key, $val) = each ($_POST))
{
$first = false;