Questions tagged [thinkphp]

ThinkPHP is a Chinese PHP framework created by 上海顶想信息科技有限公司. It's a free open-source, fast, simple object-oriented lightweight PHP development framework that was born for agile Web and small enterprise application development. Compared to Laravel, ThinkPHP had employed a light-weight and much simpler design principles. It has 2 major releases, version 3 and 5, all licensed under Apache 2 Open Source.

ThinkPHP is a PHP framework that describes itself as:

Fast,Compatible & Simple OOP MVC PHP Framework,support UTF-8、PlugIns,and Multi- databases support.

22 questions
3
votes
1 answer

Can't load controller in thinkphp

I clicked 'Create Controller' button to build a new Controller like indexController. However, it can't load and error as: FILE: F:\xampp\install\htdocs\ServerMonitorForWeb\ThinkPHP\Library\Think\App.class.php  LINE: 104 What happened to my…
xiehongguang
  • 1,274
  • 1
  • 10
  • 24
1
vote
0 answers

How you run thinkcmf framework backend locally with vue front end project

I am trying to run thinkcmf framework backend with vue front end. I get the bellow error. Cross-Origin Request Blocked: The Same Origin Policy disallows reading the remote resource at https://domainname.com:80/api/. (Reason: CORS request did not…
Feridun
  • 137
  • 7
1
vote
1 answer

Having some problem on sending cookie to server

vue+axios frontend doesn't send cookie to my php server in request header. I'm trying to move an old project to a new server. I did some optimize to the project architecture and it works perfectly fine in my local docker environment. There's some…
Frank Lee
  • 11
  • 1
1
vote
0 answers

sql_injection vulnerability in thinkphp5.0.x debug

I am recreating a sql injection vulnerability about thinkphp5.0.x I can already get the version() but I cannot get field content,it says: SQLSTATE[HY000]: General error: 1105 Only constant XPATH queries are supported` why? thinkphp 5.0.15 php…
1
vote
0 answers

How to create dynamic pdf with multiple rows?

I created one pdf from PHP. but the loop rows printed like merging foreach($details as $b => $k) { $pdf->cell(70,80,$k['name'],20); $pdf->cell(70,80,$k['order_id'],20); $pdf->cell(70,80,$k['money'],20); …
JoygiveKalai
  • 63
  • 12
1
vote
2 answers

How can i write date format in thinkphp

How can i write Date format in Thinkphp? I given the below line in my coding {$user.sdate} It shows like 10-07-1991 but i want like 10:22pm, 10-jul-1991 Every format i tried but it does not work. I tried this below one but no…
JoygiveKalai
  • 63
  • 12
1
vote
0 answers

Use of Initialization Vector in openssl_encrypt potentially insecure and not recommended

Why do I run this error on my web page? How do I initialize IV?
Fred
  • 11
  • 2
1
vote
0 answers

How can i store data from Excel to Database in ThinkPHP

I wish to store my data from Excel to Database. I am new to ThinkPHP, so i am struggling with more than 3 days. Upload is working but The data not updated into database. Error not shown in Page also. I dont know , the coding is correct or wrong.…
JoygiveKalai
  • 63
  • 12
0
votes
4 answers

PHP setcookie returns false when used with thinkphp framework

setcookie doesn't work when I use with thinkphp framework. just $a = setcookie('a','a'); no path no domain. var_dump($a) returns bool(false); no output before this, and no warning. but when I didn't use the framework , it works.
0
votes
0 answers

After modifying a php file, the method in which the file was modified does not take effect

I'm an idiot when it comes to thinkphp, recently I got a server written in it (environment is centos 7.6 and nginx) and I changed a function in a php code file, then I realized that it doesn't take effect right away, so I made these…
Syni
  • 11
  • 1
  • 5
0
votes
1 answer

1064:You have an error in your SQL syntax

1064:You have an error in your SQL syntax Is this error sql injectable because personally I'm afraid I don't know how to fix it and if it is injectable i need to fix it fast? 1064:You have an error in your SQL syntax; check the manual that…
0
votes
1 answer

SQLSTATE[22001]: String data, right truncated: 1406 Data too long for column 'xxx' at row 1

I am using thinkCMF Chinees PHP framework for the backend and Vue for the front end. I wanted to make an image upload optional and I removed it from the server required (Controller). but submitting the form it was giving the above error. I changed…
Feridun
  • 137
  • 7
0
votes
1 answer

request failed with status code 500 with vue front end and thinkcmf backend

when I request the login page with submitting it was giving above title error. I write invalid username and password it says invalid username or password but if I enter valid credentials above title error pops up. Error: Array and string offset…
Feridun
  • 137
  • 7
0
votes
1 answer

how to find the "::get" in php or its framwork?

I can not understand the ::get in thinkphp and laravel ,I can find the Session::get or the self::get .So Is the ::get is the function? I use the phpstorm but I can not find the definition of that . it is the meaning of "::get" but not the symbol of…
0
votes
0 answers

How to dynamic check whether checkbox is in another table Javascript/PHP?

I have two tables, table 1 with the fields of webID, project, web, and I use below PHP code(ThinkPHP framework) to get project list: $project = M('WebProjectList')->where(array('web' => self::$web))->getField('project', true); table 2 with the…
Elsa
  • 1
  • 1
  • 8
  • 27
1
2