Skip to content

Tag: php

WordPress – Blur Image on Upload

So I’m following the example given here (which I modified to only blur, no watermark), to make a blurred image in WordPress on upload. The problem is, that if the uploaded file is the exact same size, or smaller, than the set size, then WordPress will not generate an image, and hence no blurred one will…

Call to undefined function odbc_connect() php 7

I’m testing out php 7 and have come across this error: Fatal error: Uncaught Error: Call to undefined function odbc_connect() From the doc page: http://php.net/manual/en/function.odbc-connect.php …

Download file with ajax and php – readfile not working

I want to save a value to a txt-file and download it to the user. Right now, the value is being printed into the txt-file correctly, but the readfile function is not triggered, thus no downloading begins. The php, this code is located on the same page as the ajax call. The javascript, there is no url because …

Slim 3: how to access settings?

Before the Slim 3 is released, codes below work fine: settings.php, index.php MyClass.php But after the release, I get this error below: Notice: Undefined property: SlimApp::$settings in /… So I can’t use $app->settings anymore? What should I use then? Answer You can get settings like this:

Interpreting mysqldumpslow results

I have modified mysql config to log slow queries And interpreting them with mysqldumpslow. One of the results is as follows Question: what do the numbers in brackets mean? The query does take about 0.21s when run with mysql (or via mysql GUI’s); however when making a request to a page the time span is m…