Home PHP Libraries Other libraries mysql operation class
mysql operation class
<?php
class db
{
        var $db;
        var $position=0;
        function sub_sql($str)
        {
                global $prefix;
                return str_replace("detest_",$prefix,$str);
        }
        function Sql($str)
        {
                $str=$this->sub_sql($str);
                $result = mysql_query($str);
                $i=0;
                while($row = mysql_fetch_array($result))
                {
                        $str_array[$i]=$row;
                        $i++;
                }
                if(empty($str_array))
                {
                        $str_array=array();
                }
                $this->db=$str_array;
        }

This is a MYSQL database operation class. Friends can download it and use it.

Disclaimer

All resources on this site are contributed by netizens or reprinted by major download sites. Please check the integrity of the software yourself! All resources on this site are for learning reference only. Please do not use them for commercial purposes. Otherwise, you will be responsible for all consequences! If there is any infringement, please contact us to delete it. Contact information: admin@php.cn

Related Article

[ftp operation class] 8 php ftp operation class libraries download [ftp operation class] 8 php ftp operation class libraries download

20 May 2017

FTP is a file transfer protocol that provides client access to the file server through the File Transfer Protocol (FTP). It is used to open, log in, and close connections, and is also used to upload, download, rename, delete, and obtain files on the server. file information. PHP Chinese website provides you with 8 practical PHP ftp operation libraries for your study and reference.

[Database Operation Class] 10 PHP database operation classes download [Database Operation Class] 10 PHP database operation classes download

19 May 2017

Database operation is an important part of the development process, and being proficient in database operation is an essential weapon for developers. PHP Chinese website provides you with various encapsulated PHP database operation libraries for you to download and learn.

PHP database operation class based on pdo [can support mysql, sqlserver and oracle] PHP database operation class based on pdo [can support mysql, sqlserver and oracle]

01 Jun 2018

This article mainly introduces PHP's pdo-based database operation class, which can implement basic database connections, additions, deletions, modifications, and connections, etc. It also supports operations on mysql, sqlserver, oracle and other databases. Friends who need it can refer to it.

A PHP mysql operation class A PHP mysql operation class

25 Jul 2016

A PHP mysql operation class

PHP database operation class based on pdo PHP database operation class based on pdo

22 Jun 2018

This article mainly introduces PHP's pdo-based database operation class, which can implement basic database connections, additions, deletions, modifications, and connections, etc. It also supports operations on mysql, sqlserver, oracle and other databases. Friends in need can refer to the following

XML operation class implemented by PHP [XML Library] XML operation class implemented by PHP [XML Library]

06 Jan 2017

This article mainly introduces the XML operation class implemented by PHP, involving PHP's conversion, serialization, deserialization and other related operation skills for arrays and xml. Friends in need can refer to the following

See all articles