Tag:parameter

  • Detailed explanation of PHP sprintf() formatting usage

    Time:2021-8-2

    PHP sprintf function is a very powerful function. This article specifically records the usage of the sprintf function in PHP to format strings. Definition and Usage The sprintf () function writes the formatted string to a variable. grammarsprintf(format,arg1,arg2,arg++) Parameter descriptionFormat is required. Convert format.Arg1 is required. Specifies the parameter inserted at the first% symbol in […]

  • Understand how c# generics work

    Time:2021-8-2

    preface We all know the importance of generics in c#. Generics are the most important embodiment of polymorphism of the three major features in OOP language. Almost generics support the whole. Net framework. Before talking about generics, we can throw a problem. Now we need an array class with expandable capacity, which can meet all […]

  • Using C # to implement a simple logging framework

    Time:2021-8-2

    Translation link:https://www.infoworld.com/art… Some logs or errors are often recorded in your. Net program. In order to realize this function, you may use those existing log frameworks on the market (log4net, NLog…). Of course, you can also design and develop your own log framework. In this article, I will take you how to easily and happily […]

  • Encapsulating Ajax

    Time:2021-8-2

    Problem: there are too many Ajax request codes sent once, and the request codes sent many times are redundant and repeated Solution: encapsulate the request code into the function and call the function when sending the request 1. Simple version function ajax(mether, url, callback, data, flag) { //Asynchronous or not, asynchronous by default flag = […]

  • Docker builds PHP environment

    Time:2021-8-2

    Version introduction cliCommand line version apacheApache version fpmReverse proxy version alpineCompact version buster & stretchFor Debian distribution Mode of use Method 1: build based on dockerfile vim Dockerfile FROM php:7.3-fpm RUN mv “$PHP_INI_DIR/php.ini-production” “$PHP_INI_DIR/php.ini” COPY . /usr/src/myapp WORKDIR /usr/src/myapp CMD [ “php”, “./your-script.php” ] $ docker build -t my-php-app . $ docker run -it –rm […]

  • How to upload files in ASP. Net core MVC

    Time:2021-8-2

    ASP. Net core MVC implementsUpload fileDirectly map to the model, as long as the model is implementedIFormFileJust interface. Recall,model bindingThe function of is to map the request to the action method parameters, which simplifies the original direct access to the request and facilitates subsequent unit testingIFormFileThe interface simplifies access to the file in the request. […]

  • Spark – RDD usage

    Time:2021-8-1

    Resilient distributed dataset (RDD) is the core concept in spark. To put it simply, create an RDD in spark, and then perform various operations on the data through RDD. RDD creation The creation of RDD includes: Create from collection Create from other storage such as HDFS, local files, etc Create from other RDDS The following […]

  • Vue Foundation (x): Vue routing (II)

    Time:2021-8-1

    1. Routing 1.1 Vue router dynamic route matching 1.1.1 basic usage of dynamic matching routing Application scenario: route matching through the mode of dynamic routing parameters. Document User1 User2 User3 Register const User = { //Get routing parameters through $route.params in the routing component Template: ‘< H1 > user component — user ID: {{$route. Params. […]

  • Remember the pit caused by an overly intelligent production tool

    Time:2021-8-1

    background Recently, a cli tool for processing proto files was developed. Previously, proto files were used in two ways: Directly reference the proto file and dynamically generate JS code at runtime Generate the corresponding JS file through the protocol tool and reference it in the project The latter will have higher performance, because the compilation […]

  • The most powerful Java logging framework has invincible performance and swept all competitors..

    Time:2021-8-1

    Logback is an old logging framework in Java. It has been iterating for more than ten years since its first version in 2006. However, the latest stable version of logback is still in 2017 and has not been updated for several years; The last stable version of logback’s brother slf4j is also 2017, which means […]

  • Use reaction, an exquisite hook based modular data management scheme

    Time:2021-7-31

    brief introduction React app state management (Data Management) has always been an essential link in project development. Small projects can use usestate / setsate in their components. However, for slightly more complex projects, the introduction of state management frameworks, such as Redux, mobx, DVA and so on, will be considered again and again.For complex projects, […]

  • Solution to the problem of signature verification failure in IOS configuration wechat config

    Time:2021-7-31

    In the development, there is a problem about wechat configuration. The development tools and framework used are uniapp and jssdk   jweixin Using uniapp to develop official account requires WeChat configuration to change information when entering a page.   Problem Description: Request the background to obtain the wechat configuration parameters and configure the wechat parameters […]