laravel+GatewayWorker completes IM instant messaging and file transfer (Chapter 5: front end code development)

Function introduction This topic will take you hand-in-hand to build the instant messaging function of imitating a letter and complete the mutual transmission of documents Application scenario Practical application scenarios of this topic: Chat customer service: instant messaging, real-time message transmission, sending text, voice mess ...

Posted on Fri, 03 Dec 2021 22:25:11 -0500 by fleabay

18 use of v-if combined with template tag in V-for

v-for cyclic number v-for can be used to cycle numbers. For example, if you want to cycle numbers 1-99, you can write them directly as follows. <span v-for="count in 99">{{count}},</span> In this way, you can quickly cycle out the value of 1-99 on the page. You can see this effect in the browser. <!DOCTYPE html> <h ...

Posted on Wed, 01 Dec 2021 21:55:46 -0500 by afrim12

Introduction to InfluxDB and php usage

InfluxDB (time series database) is a common use scenario: monitoring data statistics. Record the usage of computer memory every millisecond, and then use the graphical interface (InfluxDB V1 generally cooperates with Grafana) to make a broken line diagram of memory usage according to the statistical data;The input of reference text here can be ...

Posted on Wed, 01 Dec 2021 07:47:35 -0500 by kath421

Customize paging information when using the Laravel Resource class

A recent submission to the Laravel framework idea - Add a detection of a custom paging information method to the PaginatedResourceResponse to make it very easy to customize the paging information when using the Resource class to output information. Why need it I'm basically developing an API. In the early days, I always returned directly, bu ...

Posted on Tue, 30 Nov 2021 14:44:48 -0500 by vB3Dev.Com

20 Laravel Eloquent tips and tricks

Eloquent ORM seems to be a simple mechanism, but behind the scenes, there are many semi hidden functions and little-known methods to achieve more functions. In this article, I'll show you some tips. 1. Increment and decrement Instead of the following implementation: $article = Article::find($article_id); $article->read_count++; $article-& ...

Posted on Mon, 22 Nov 2021 12:33:30 -0500 by tilde

How to use federated index correctly in MySQL tuning

One business is to query the latest approved 5 pieces of data SELECT `id`, `title` FROM `th_content` WHERE `audit_time` < 1541984478 AND `status` = 'ONLINE' ORDER BY `audit_time` DESC, `id` DESC LIMIT 5; Check the monitoring situation at that time. The cpu utilization rate is over 100%. show processlist sees that many similar queries ...

Posted on Thu, 11 Nov 2021 05:50:10 -0500 by sweetstuff2003

Based on laravel architecture

Architecture diagram1. Request log the request message log. The reason for adding the request message here is that in many cases, the BUG is difficult to reproduce at low frequency. The original request message can well troubleshoot the problem. This layer can also be placed in Middleware to handle the reference example:<?php namespace App\ ...

Posted on Mon, 01 Nov 2021 22:38:50 -0400 by adunphy

As a single thread, Redis is oversold when I use it?

Focus on PHP, MySQL, Linux and front-end development. Thank you for your attention!!! The article is arranged in GitHub,Gitee The technologies mainly include PHP, Redis, MySQL, JavaScript, HTML & CSS, Linux, Java, Golang, Linux, tool resources and other relevant theoretical knowledge, interview questions and practical content. Practical de ...

Posted on Mon, 25 Oct 2021 09:16:09 -0400 by Courbois

Summary of common array functions

a key array() creates an array. array_change_key_case() changes all keys in the array to lowercase or uppercase. array_chunk() splits an array into new array blocks. $cars=array("Volvo","BMW","Toyota","Honda","Mercedes","Opel"); print_r(array_chunk($cars,2)); //Array ( [0] => Array ( [0] => Volvo [1] => BMW ) [1] => Array ( [0] ...

Posted on Tue, 12 Oct 2021 20:14:46 -0400 by Dizzee15

Wechat applet front and rear authorized login

1, Wechat applet front end 1.1 applet front end preparation Due to the use of Web vant, it has not been installed or does not know how to install it. You can refer to it My blog. upper Wechat public platform Register a small program. After registration, you will have APPID and SECRET. 1. api encapsulation The wxapi folder is defined in ...

Posted on Mon, 04 Oct 2021 21:10:39 -0400 by Maknis