Skip to content

Laravel 8 eloquent query delete

How to delete the aircon in database when there is no any data. Order and Aircon are many to many relationship. Answer try whereDoesntHave Edit: You can also add new column aircons_count will old number of aircons for every order which will be faster than the above query and run the query like the following: …

Cant run pdflatex command (Tex Live) on Plesk

I got a problem with an API (PHP) I created. The API should create a pdf document depending on the data that is sent. The script works perfectly, running it directly on Ubuntu, Plesk is running on. The part that is not working is the following: The tex-file seems not to be touched… no log files or anyth…

Why can’t get query from sqlsrv ci3

//this my config db: ‘dsn’ => ”, ‘hostname’ => ’10.***.***.*’, ‘username’ => ‘username’, ‘password’ => ‘password’, ‘database’ => ‘mydb’, ‘dbdriver’ => ‘sqlsrv&#…

How to use PHP code in inline CSS in HTML

I’d like to use my PHP code in Inline CSS. Let me show the code: This is my code: This is what I want to achieve: But instead, I get this: What can I do to make CSS read 22 from my PHP code? I want to change the width by changing the PHP code. By the way I’m using

Display items with id from an array

So i created a column in my database that accepts JSON array, inside these array are item id’s , i want to create a loop on those ids and insert it in an sql select statements to display all items that has the ids in the array, but im clueless on how to do it. Answer As you are storing