zan-framework mysql connection example tutorial

零下一度
Release: 2023-03-10 17:04:01
Original
980 people have browsed it

①Configure the read and write whitelist of the sqlmap connection pool according to the document content

http://doc.zanphp.io/zh/libs/connection_pool.html

Sample code

// demo.demo.demo_sql_id1_1 corresponds to the configuration in resource/demo/sql/demo.php
$result = (yield Db::execute("demo.demo.row_sql_id1_1" , $data));

②Get get, post, request information

There is a built-in function, if you call $ directly in the controller this

Sample code

$request = $this->request->get('content');//Get the request content

The above is the detailed content of zan-framework mysql connection example tutorial. For more information, please follow other related articles on the PHP Chinese website!

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!