Tag:php

  • Long connection, short connection, long polling, short polling and websocket

    Time:2020-7-13

    See a good article, specially reprinted, the original address: long connection, short connection, long polling, short polling, websocket 1、 Short connection and long connection Short connection: TCP connection will be established for each HTTP request, which is easy to manage Long connection: you only need to establish a TCP connection once. Later, HTTP requests reuse […]

  • [tutorial] restful API using JWT authentication in laravel

    Time:2020-7-9

    This article is forwarded from the professional laravel developer community, original link: https://learnku.com/laravel/t… In this article, we’ll learn how to use JWT authentication to build restful APIs in larevel. JWT stands for JSON web tokens. We will also use the API to create full-featured crud applications for user products. When using cross platform applications, the […]

  • PHP express logistics order number query API demo address free call

    Time:2020-7-8

    With the rapid development of online shopping era and express industry, people pay more and more attention to express query service. This paper provides you with a good PHP source code development program for Express query API interface, which can track the logistics information of hundreds of express and logistics companies, such as four links […]

  • Analysis of del of redis command

    Time:2020-7-7

    baiyan Command syntax Command meaning: delete the value corresponding to a keyCommand format: DEL [key1 key2 …] Command actual combat: 127.0.0.1:6379> del key1 (integer) 1 Return value: the number of deleted keys Source code analysis First, we open a redis client and use the port of GDB – P redis server. Since the processing function […]

  • PHP observer pattern definition and usage example analysis

    Time:2020-7-7

    This article describes the definition and usage of PHP observer pattern. For your reference, the details are as follows: The observer pattern I understand is that when we trigger an event, we want to tell the object that I want to tell this operation, and let them all perform the operation, that is to bind […]

  • How can blockchain become the next Internet?

    Time:2020-7-6

    As the “opposite” of the Internet, blockchain is the new technology that is most likely to become the next development outlet. After the early barbaric growth and industry winter, people’s understanding of blockchain began to be rational gradually. Although there are still some people who regard blockchain and digital currency as a link, it would […]

  • How to use the trait in PHP

    Time:2020-7-6

    summary There is a code reuse technology in PHP. Because of the single inheritance problem, some public methods cannot be written in the parent class. However, trait can deal with this situation. It can define some reuse methods and then introduce them into the classes you need to use At first, it gave me the […]

  • Use eloquent withcount() to count the number of corresponding relationships

    Time:2020-7-5

    This article is forwarded from the professional laravel developer community, original link: https://learnku.com/laravel/t… Eloquent has a little-known function calledwithCount(): it can help to get the number of records associated with objects including remote one to many relationships. Let’s look at an example. In our sample project, we have three models:User,PostAndComment。 All the relationships can be […]

  • Analysis of dump of redis command

    Time:2020-7-4

    Grape Official documents DUMP keySerialize the given key and return the serialized value. Use the restore command to deserialize the value to the redis key.The values generated by serialization have the following characteristics: It has 64 bit checksums for error detection, and restore checks the checksums before deserializing. The encoding format of the value is […]

  • Analysis of the implementation method of PHP reading directory tree

    Time:2020-7-4

    This paper describes the implementation of PHP reading directory tree. For your reference, the details are as follows: A while ago, there was such a question in the written examination of XX company: Use PHP to list the directory tree! At that time, I was confused! There are still some basic ideas, but the use […]

  • Development and production of Mengchong ecosystem app

    Time:2020-7-3

    Application skills of ThinkPHP + mengpet ecosystem app development (T: i8o, 2853, 296o V Li can)1. Format the file under Runtime: define (‘strip_ RUNTIME_ SPACE’,false);2. Development time does not cache: entry file: define (‘No_ CACHE_ RUNTIME’,true);3. ThinkPHP supports four access modes: A: normal mode B: pathinfo mode C: rewrite mode D: compatibility mode using URL […]

  • A simple way to install PHP extension by shell script

    Time:2020-7-3

    Examples are as follows: #!/bin/bash #This script is to install PHP extensions #Author=steven #[email protected] #WriteTime=Sun Aug 14 23:32:18 CST 2016 #The environment variable Extension_HOME=/usr/local/src/php-5.6.16/ext/mysql PHP_HOME=/usr/local/webserver/php Extension_Install=mysql.so #Enter the extension directory cd $Extension_HOME #Some of the set about PHP plugin modules $PHP_HOME/bin/phpize #Target characteristics of the test installation platform $Extension_HOME/configure –with-php-config=$PHP_HOME/bin/php-config #compile make #install make install […]