Swoole learning notes: getting started with Hprose

1. What is RPCRPC is a way of communication between processes, the full name is "remote call procedure".When a client sends a request to the server, it is not sent directly to the target server, but to the RPC Server, which schedules it.RPC provides remote calling methods that are no different from calling local methods. 2. Introduct ...

Posted by Eddie Fisher on Sun, 17 Nov 2019 13:45:17 -0800

php7 compile and install PDO ﹣ msql module

Compiling and installing PDO MySQL extension of php7 Note the execution path of all the following codes. If your file is not in the path of the sample code, please execute it in the corresponding path of your own file The premise is that php7 is already installed using source code. Otherwise, you need to download the source code of PDO MySQL ...

Posted by vornn on Wed, 13 Nov 2019 09:52:47 -0800

Exceptions

nested exception Before we learn about SPL exceptions, let's take a look at nested exceptions. As the name implies, nested exceptions are nested inside the Exception. An Exception is thrown, and an Exception is thrown after the catch arrives. In this case, nested exceptions can be obtained by the getPrevious method of the Exception base class; ...

Posted by mdowling on Fri, 08 Nov 2019 10:15:14 -0800

Compatibility of Logic Operators of SQL Statements "AND", "&&"

Recently, I plan to transfer my blog to the typecho platform and choose a theme that I personally prefer. Akina for Typecho Theme Template Thank you for the open source sharing of the theme, but there was a "500 Database Query Error" problem at the beginning of the use process.Add the following code at the beginning of the index.php f ...

Posted by phpCCore Brad on Sun, 06 Oct 2019 09:15:08 -0700

Three Ways of Laravel 5 Operating Database

1. DB facade (original lookup) // query $objectArray=DB::select('select * from student'); foreach ($objectArray as $obj){ echo $obj->id; } // insert $bool=DB::insert('insert into student(name,age) values(?,?)',['tom',18]); // modify $num=DB::update('update student se ...

Posted by jboy6t9 on Mon, 30 Sep 2019 01:06:13 -0700

DVWA-CSRF (Cross-Station Request Forgery)

CSRF: (Cross Site Request Forgery), an attacker constructs a request address of a functional interface in the background of a website, induces users to click on it or uses special methods to load the request address automatically. When the user is lo ...

Posted by FlyingIsFun1217 on Tue, 20 Aug 2019 00:30:39 -0700

Basic knowledge of php

Basic introduction php marker <? php?> If the content of the file is pure PHP code, delete the PHP end tag at the end of the file. You can avoid accidentally adding spaces or newlines after the end tag of PHP, which will cause PHP to start outputting these blanks without the intention of output in the script at this time. <? ...

Posted by makeshift on Mon, 01 Apr 2019 12:24:29 -0700

thinkphp Distributed Database

1. distributed data base What is it? The distributed database of tp is mainly through this configuration: DB_DEPLOY_TYPE'=> 1, //database deployment: 0 centralized (single server), 1 distributed (master-slave server) 2. What is the read-write separation between master and slave servers? A master-slave database is a master database with n ...

Posted by geek_girl_2020 on Fri, 29 Mar 2019 22:57:28 -0700

The use of pdo in php

Step 1: Test whether pdo is enabled: Run the following code to indicate that the PDO has been installed if the parameter is wrong. If the description object does not exist, modify the PHP configuration file php.ini and cancel the previous comment on php_pdo_yourssqlserverhere.extis. $test=new PDO(); Warning: PDO::__construct() expects a ...

Posted by pstevereynolds on Mon, 25 Mar 2019 01:57:27 -0700

PHP Design Patterns - DAO (Data Access Objects) Data Access Object Patterns

Tidy up your study Aaron Saray Write some demo s of PHP design patterns and their own understanding. If you find that your contempt has misunderstood, please point out immediately. Thank you for patting bricks and kneeling for whipping. /** * DAO (Data Access Objects) Data Access Objects * ------------------------------------- * ** From Exp ...

Posted by chigley on Tue, 12 Feb 2019 18:27:19 -0800