public function categories() { return $this->belongsToMany( PortalCategoryModel , portal_category_post , category_id , post_id , type ); } The type field has no data. According to the official case, there are only four parameters. A...
** * * public function categories() { return $this->belongsToMany( AudioCategoryModel , portal_category_post , category_id , post_id ); } id=27, is 27 records of the content table $id = $this->request->param( id ...
public function __call($method, $args) { if (!require_cache("{$this->addonPath}Controller AdminController.class.php")) { E("database"); } $object = Think Think::instance(" A...
there is a Uploads directory under the root directory, which can be correctly identified by accessing the image files through url, but non-image files will prompt that the Uploads controller does not exist, what?? What logic? xxxxx.com Uploads proje...
output the result of $_ GET as shown in the figure, using the framework of tp3. Why is the result like this? ...
I am doing an official account Wechat login. I jump to Wechat s authorization with the following code: header("Location:https: open.weixin.qq.com connect oauth2 authorize?appid=".$this->appid."&redirect_uri=".$REDIRECT_URI...
problem description 501234. 13 the environmental background of the problems and what methods you have tried TP5 : where( state ,1)->select*() where( state ,3)->select*() what result do you expect? What is the error message actually seen? ...
I am not familiar with just using thinkphp, when you generate a module using commands such as php think crud test, you find that only the admin module is generated and is only available in the background. Can you directly generate the corresponding mo...
for example, in the root directory of the project, there is a head directory where there is a 1.jpg picture. I want to use this picture in the view, so how do I write the src path of the img tag? ...
use thinkphp5.1x for api interface development when doing the list query interface: you want to use parameters to control the returned data of the query, roughly as follows null what exactly is my problem and is there a security risk in my wa...
I wrote a mysql database operation class, and then I wrote a model class for each table, and these model inherits the mysql database operation class. My mysql database operation class is in the form of a singleton class. Yesterday, when debugging the co...
there is a sql statement that you want to construct with the constructor of tp5, as follows Select * from tab1 where (axi1 and baked 1) or (a2 and baked 2) or (axi3 and baked 3) .or (aural N and baked N) Note: when N is equal to, there are as many o...
$condition there will be a time condition, this time condition is optional, now think if the time condition does not exist, how to remove the time condition? When the time condition exists, then add the query result of the time condition? method 1: an...
only admin users who send messages in Aurora im have this permission, so why do ordinary users still need to register, and ordinary user face messages can not be sent? why? ...
config.php has no restrictions as follows UPLOAD_SITEIMG_QINIU = > array () rootPath = > . , saveName => array ( uniqid , ), driver => Qiniu , driverConfig => array ( secrectKey => 1111 , ...
thinkphp 5.0.7. Ajax is used in view to submit post data. After the data is submitted, it cannot be printed through tp. After studying it for a long time, I really don t know what went wrong. A very simple test code, Front end: <html> ...
before the code is written in Controller, too much writing is bloated, and it looks so messy. Now that I ve changed it to this, I don t know exactly how to calculate the industry standard. If it feels like this, it will be a little clearer. controlle...
when I query a user s information, including editing a user s information when the user exists and there is no such data time in the database, Laravel reported me such an error (2amp 2) NotFoundHttpException No query results for model [AppModelUse...
< eq name= "{: C ( login_verify )} " value= "1 " > this makes an error ...
how to prevent thinkphp from displaying the page you want to view has an error and will jump automatically after two seconds! but directly display the specific error? ...
$this->validate($request,{ id => required|integer }); how to validate the field integer or array when validating the same field ...
as shown in the figure, there is no error message. After App starts, there is only one loading page, and then it flashes. ...
If the component does not provide an interface to set the width and height, what if you want to change the width and height yourself? the current method is to use important override reset in the scss file that initializes global variables, which is un...
the following is the configuration file for gulpfile.js const gulp = require( gulp ) gulp const uglify = require( gulp-uglify ) js const jshint = require( gulp-jshint ) js const minifyHtml = require( gulp-minify-html ...
For the project of vue, there are many data modules on the home page. You need to call different API to get the data, and the request will slow down the loading of the first screen. How to optimize it? ...