Uncategorized
Solr and WordPress (instructions/howto)
This is for Tomcat5.5 (on Debian Lenny), WordPress 3.1 and Solr 3.4. The intention is to use the solr-for-wordpress plugin (see github ). Lenny does include a Solr package (v1.2) which is somewhat outdated (and not supported by the upstream solr-for-wordpress wordpress plugin, hence we can’t use it). Install Tomcat (and Java) apt-get install sun-java6-jre … Continue reading
wp-mobile-detector is insecure (wordpress plugin)
It seems installing the wp-mobile-detector plugin on your wordpress site is a bad idea {tm} A customer’s web server has the following requests in it : [24/Aug/2011:02:10:47 +0100] “HEAD /wp-content/plugins/wp-mobile-detector/timthumb.php?src=http://superflickr.com.nu/index.php HTTP/1.1″ 200 – “-” “Mozilla/5.0 (Windows; U; Windows NT 5.1; ru-RU; rv:1.7.12) Gecko/20050919 Firefox/1.0.7″ [24/Aug/2011:02:10:48 +0100] “GET /wp-content/plugins/wp-mobile-detector/cache/27a44a2d2bea4a693389c325a1125aa6.php HTTP/1.1″ 200 52 “-” “Mozilla/5.0 (Windows; U; … Continue reading
Slim Framework – using middleware for page caching in the front controller
The SlimFramework is a ‘minimal’ PHP5 framework. We’re using it in one project, integrating with Smarty, Propel and the Zend Framework (as I don’t like Zend_View, it didn’t seem worth using Zend_Controller_Action, although what we do have is very similar to one). Anyway, when creating your front controller in Slim, you can define ‘middleware‘ (i.e. … Continue reading
Ebuyer & ParcelForce – a story in how not to treat your customer
5-6 weeks ago ago I ordered two 24″ widescreen monitors from EBuyer - when the ParcelForce guy delivered them I told him I expected 2, and there was only one delivered. He walked off. I presumed that the other would arrive the next day or something… but it didn’t. while(true) { David.ContactsEBuyerViaStupidENoteSystem(‘rah rah rah … Continue reading
Upgrading iPhone – the iphone could not be restored an unknown error occurred 1013
On seeing JailBreakMe has released a new version – which allows me to upgrade to the 4.3.3 firmware – I thought I’d update my iPhone4 – but annoyingly kept getting the following error message (whether doing an update or a full restore) : “The iphone could not be restored an unknown error occurred 1013″ In … Continue reading
Delaying external javascript/content loading on a website…
One customer of ours, has a considerable amount of content which is loaded from third parties (generally adverts and tracking code). To the extent that it takes some time for page(s) to load on their website. On the website itself, there’s normally just a call to a single external JS file – which once included … Continue reading
Running along….
I think I’m back into my running ‘habit’ again, after finally overcoming an achilles tendon and so on. I randomly installed RunKeeper on my iPhone, and I seem to be running at about 4minutes 30seconds per kilometer (I did 9.6km at this pace). The furthest I’ve been recently is about 13-14 miles, I think… So, … Continue reading
Magento not finding product images (solution)
I migrated a Magento instance from one host to another, and in the process earnt myself some free beer; everything went well, apart from some of the thumbnail images not appearing. The image URLs would look like : /media/catalog/product/cache/1/image/5e06319eda06f020e43594a9c230972d/images/catalog/product/placeholder/image.jpg Things tried which didn’t help : rebuilding various Magento image caches and so on (login as … Continue reading
Getting a kvm serial console with grub2
I’ve a few kvm guest servers, which I’ve been accessing using vnc – but this is a bit of a pain (getting port forwarding setup etc). Host and guests run Debian Squeeze with Grub2 installed/in use. So, here’s how to do the ‘virsh console ‘ thing … Edit /etc/default/grub, specify GRUB_TERMINAL=serial GRUB_SERIAL_COMMAND=”serial –unit=0 –speed=115200 –word=8 … Continue reading
fsck -y (or fsck yes…)
Tip for the day: Edit /etc/default/rcS on Debian/Ubuntu servers, and set FSCKFIX=yes (default of no) so next time your server runs fsck at startup, and spends hours doing it to only moan when it finds an error, and tells you to waste more time by running fsck with ‘-y’ (to fix it). Quite why fsck … Continue reading