1
0
mirror of https://git.tt-rss.org/git/tt-rss.git synced 2025-12-13 13:35:56 +00:00

remove $link

This commit is contained in:
Andrew Dolgov
2013-04-17 16:23:15 +04:00
parent aca75cb5cb
commit 6322ac79a0
80 changed files with 1624 additions and 1727 deletions

View File

@@ -1,6 +1,5 @@
<?php
class Note extends Plugin {
private $link;
private $host;
function about() {
@@ -10,7 +9,6 @@ class Note extends Plugin {
}
function init($host) {
$this->link = $host->get_link();
$this->host = $host;
$host->add_hook($host::HOOK_ARTICLE_BUTTON, $this);
@@ -29,9 +27,9 @@ class Note extends Plugin {
}
function edit() {
$param = db_escape_string($this->link, $_REQUEST['param']);
$param = db_escape_string( $_REQUEST['param']);
$result = db_query($this->link, "SELECT note FROM ttrss_user_entries WHERE
$result = db_query( "SELECT note FROM ttrss_user_entries WHERE
ref_id = '$param' AND owner_uid = " . $_SESSION['uid']);
$note = db_fetch_result($result, 0, "note");
@@ -58,10 +56,10 @@ class Note extends Plugin {
}
function setNote() {
$id = db_escape_string($this->link, $_REQUEST["id"]);
$note = trim(strip_tags(db_escape_string($this->link, $_REQUEST["note"])));
$id = db_escape_string( $_REQUEST["id"]);
$note = trim(strip_tags(db_escape_string( $_REQUEST["note"])));
db_query($this->link, "UPDATE ttrss_user_entries SET note = '$note'
db_query( "UPDATE ttrss_user_entries SET note = '$note'
WHERE ref_id = '$id' AND owner_uid = " . $_SESSION["uid"]);
$formatted_note = format_article_note($id, $note);