we have a super strange error only on one (mac) machine of our team. It works on others well. System Setup: OS: Mac OS X Mojave 10.14.6 Browser: Iron php 7.4.3 The error when accessing …
Tag: php
Echo Array Values in Comma Separated List
I am selecting values from my database, when I dump the $results I get; array ( 0 => (object) array( ‘FieldName’ => ‘certification_name’, ‘FieldValue’ => ‘White Belt’, ), …
WordPress: Get child taxonomies only from one level down
I want to display the WooCommerce sub-categories based on the current categorie ID. To get all sub-categories, I’m using the following code to get all child IDs. The problem is, that I get all …
why am I not redirected after a ajax post?
I’m using a page (file1.php) to submit a specific number to another php file (file2.php) this second PHP file as to take data from a database and extract information then return it to file1.php, here …
update and regenerate thumbnails for wordpress multisite
For my multisite installations (with over 1500 sites on one of them) I am looking for the most efficient way to change the thumbnailsite to 300×300. On a single site you can easily do this by changing …
Search a google spread sheet using JQuery
I want to search a specific column in my google spreadsheet which contains strings. I used PHP to read the data from the sheet and stored them into an array. Printing the array shows me the column values, however when using (json_encode), I am only getting the last value in the array which is pretty weird. He…
PHP MySQL Grouping Issue
If I have a table with the following data in MySQL: Company CompanyEntity OrderNumber Delivery Date Deeway HS 20779 4608580 2020-11-11 Deeway …
output of docker container
I have this docker file: FROM php:7.4-cli COPY . /src/ WORKDIR /src/ CMD [ “php”, “./src/index.php” ] ANd I’m using this two commands to run it: docker build -t php_script . winpty docker run -it –…
How to “mock” Sentry client in the PHPUnit tests
In case if you need to test PHP application error handlers, you have to “mock” or just disable sending errors on remote servers in the Sentry client. What is the right way to do this?
Laravel joining tables in a database query
I have this code: $classic_games_money = DB::table(‘bets’) ->where(‘user_id’, $this->user->id) ->sum(‘price’); It displays the amount of income, but i need to display this …