note 108007 added to mysqli-result.num-rows

From: Date: Thu, 22 Mar 2012 00:00:08 +0000
Subject: note 108007 added to mysqli-result.num-rows
Groups: php.notes 
Request: Send a blank email to php-notes+get-186763@lists.php.net to get a copy of this message
<?php class mysqlisimple extends mysqli { public function __construct($hostname, $username, $password, $database) { $this->connection = @parent::__construct($hostname, $username, $password, $database); if($this->connection->connect_error) { die($this->connection->connect_error); } } public function DBResult($query) { $this->PrepareQuery = $query; if ($this->Result = $this->query($this->PrepareQuery)) { while ($this->row = $this->Result->fetch_row()) { $this->output = $this->row[0]; } } return $this->output; } } ?> This is a simple class to extend MySQLi and includes a function to fetch a single result. Was just playing, thought it may help some. ---- Server IP: 69.147.83.197 Probable Submitter: 202.0.58.194 ---- Manual Page -- http://www.php.net/manual/en/mysqli-result.num-rows.php Edit -- https://master.php.net/note/edit/108007 Del: integrated -- https://master.php.net/note/delete/108007/integrated Del: useless -- https://master.php.net/note/delete/108007/useless Del: bad code -- https://master.php.net/note/delete/108007/bad+code Del: spam -- https://master.php.net/note/delete/108007/spam Del: non-english -- https://master.php.net/note/delete/108007/non-english Del: in docs -- https://master.php.net/note/delete/108007/in+docs Del: other reasons-- https://master.php.net/note/delete/108007 Reject -- https://master.php.net/note/reject/108007 Search -- https://master.php.net/manage/user-notes.php

« previous php.notes (#186763) next »