Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
[plugin] change mysql_* function to DB object method
  • Loading branch information
nao-pon committed Sep 6, 2013
1 parent 9c6855e commit aaeb78b
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion xoops_trust_path/modules/xpwiki/class/attach.php
Expand Up @@ -1299,7 +1299,7 @@ function XpWikiAttachPages(& $xpwiki, $page='',$age=NULL,$isbn=true,$max=50,$sta
$query = "SELECT DISTINCT p.pgid FROM ".$this->xpwiki->db->prefix($this->root->mydirname."_pginfo")." p INNER JOIN ".$this->xpwiki->db->prefix($this->root->mydirname."_attach")." a ON p.pgid=a.pgid{$where}";
$result = $this->xpwiki->db->query($query);

$this->count = $result ? mysql_num_rows($result) : 0;
$this->count = $result ? $this->xpwiki->db->getRowsNum($result) : 0;

$this->max = $max;
$this->start = $start;
Expand Down
2 changes: 1 addition & 1 deletion xoops_trust_path/modules/xpwiki/plugin/dbsync.inc.php
Expand Up @@ -665,7 +665,7 @@ function plain_db_init()
$id = $this->func->get_pgid_by_name($page, FALSE, TRUE);
$query = "SELECT plain FROM `".$this->xpwiki->db->prefix($this->root->mydirname."_plain")."` WHERE `pgid` = ".$id.";";
$result = $this->xpwiki->db->query($query);
if ($result && mysql_num_rows($result))
if ($result && $this->xpwiki->db->getRowsNum($result))
{
list($text) = $this->xpwiki->db->fetchRow( $result );
if ($text && !$this->root->post['plain_all'])
Expand Down
Expand Up @@ -214,7 +214,7 @@ function plugin_exifshowcase_body($args,$page)

$query = "SELECT name FROM `".$this->xpwiki->db->prefix($this->root->mydirname . "_attach")."` WHERE {$where}{$order};";
$result = $this->xpwiki->db->query($query);
while($_row = mysql_fetch_row($result))
while($_row = $this->xpwiki->db->fetchRow($result))
{
$files[$_row[0]] = $this->cont['UPLOAD_DIR'].$this->func->encode($page).'_'.$this->func->encode($_row[0]);
}
Expand Down

0 comments on commit aaeb78b

Please sign in to comment.