<?php
- set_include_path(get_include_path() . PATH_SEPARATOR .
- dirname(__FILE__) . "/include");
-
- function __autoload($class) {
- $file = "classes/".strtolower(basename($class)).".php";
- if (file_exists($file)) {
- require $file;
- }
- }
+ set_include_path(dirname(__FILE__) ."/include" . PATH_SEPARATOR .
+ get_include_path());
+ require_once "autoload.php";
require_once "functions.php";
require_once "sessions.php";
require_once "sanity_check.php";
$link = db_connect(DB_HOST, DB_USER, DB_PASS, DB_NAME);
- if (!init_connection($link)) return;
+ if (!init_plugins($link)) return;
$op = $_REQUEST['op'];
if ($op == "publish"){
- $key = db_escape_string($_REQUEST["key"]);
+ $key = db_escape_string($link, $_REQUEST["key"]);
$result = db_query($link, "SELECT owner_uid
FROM ttrss_access_keys WHERE