Author: MC
-
Experimenting with Googlebot
In my previous post ‘Blogs are fundamentally flawed…‘ I noted an observation that more often than not search results would direct a user to an index-style page containing the post instead of directly to the ‘permalink’ location of the post. This leads to a poor user-experience from the visitor’s point of view, on busy blogs…
-
Blogs are fundamentally flawed for the typical Grandma-User
It may seem a little sad but I can honestly say that reading my access_log is far more interesting than any soap opera on TV; they are filled with exotic foreigners, futuristic robots, drama, intrigue and personal tragedy. The best thing about it is that it’s all real; these are (mostly) real people who stumble…
-
Horde 3.0.8 appears to be broken
Horde is an application framework used by a web-based email client IMP I use to read my email. From the Horde site [www.horde.org]: The Horde Project is about creating high quality Open Source applications, based on PHP and the Horde Framework. The guiding principles of the Horde Project are to create solid standards-based applications using…
-
‘NASA Search 1.0’ ??? Something Google should worry about ???
Having written my own WordPress logging / statistics plug-in over the weekend – which still in prototype, consider it a ‘coming soon’ – I have started to notice more and more peculiar User-Agents visiting my blog. I quite like to keep an eye on what spiders / bots visit my sites, how often they return…
-
Charset detection for fun and non-profit…
FreeDB [www.freedb.org] is a free online CD-information database allowing applications to query the FreeDB server over the internet for disc & track titles. The database was built with user-submitted information; as such entries were being submitted in whatever default character set the submitting-user had. The problem arises when someone with a different default character set…
-
Using MEncoder to convert a DVD to DivX
More for my own benefit, but here goes… This is an example of using MEncoder (Windows version) to convert a DVD to DivX. The original movie was widescreen and is being rescaled here to 720×408 to keep the 16:9 aspect ratio. The video bitrate I used was 1024kbit but you can tweak this as desired.…
-
MediaCodeSpeedEdit tool for DVD-Writers by ala42
Stumbled across this when trying to find out why my 16x DVD media wouldn’t burn at anything higher than 4x. Download your drive’s latest firmware, feed it into MediaCodeSpeedEdit and you can edit the burn speeds for all media the drive can recognise. Save the modified firmware and re-flash your drive with it. Pretty neat!…
-
[Oracle Toplink] Importing a 10.1.3DP3 project into the 10.1.3DP4 workbench doesnt work…
// TODO Write more about it 😀 http://forums.oracle.com/forums/message.jspa?messageID=1030494
-
Perl – Using HTTP::Lite
I recently had to use the HTTP::Lite perl module and thought I would share an example of how to use it. HTTP::Lite was is available on www.cpan.org; its very lightweight and has no dependancies other than Socket & Fcntl which included with almost all Perl implementations by default. Based on the examples by the HTTP::Lite…
-
Velocimacro – Generate a HTML Select box and its Options
A quick and simple Velocimacro to generate HTML Select boxes and its Options; automatically selects the correct option based on the value given. You can place this #macro anywhere in your Velocity templates but I used my global VM_global_library.vm file. Code [code] #macro( generateSelectBox $name $options $value ) #foreach ( $option in $options ) #set(…
-
Determine the number of open files in your program (C/C++)
The code below will display the number of files open by the running process. It does this by getting the maximum file descriptor number and then iterating through each possible fd trying to do an ‘fstat’ on it. If errno returns anything other than EBADF ‘file descriptor is bad’ it increments a count. It is…
-
JSSHTunnel 0.0.0 Released!
JSSHTunnel is a lightweight GUI application which forwards local & remote ports over SSH connections. It is written in Java and uses Eclipse SWT & JSch. All you need is a JVM to run it. I’ve released version 0.0.0, it is under GPL. Features & Limitations in 0.0.0: Targetted at Windows platform, comes with a…
-
Linux Bluetooth “Device is not available: Success”
Symptom Trying to use hcitool returns the ambiguous error message “Device is not available: Success” [code] [root@localhost ~]# hcitool scan Device is not available: Success [root@localhost ~]# [/code] Solution Start ‘Bluetooth services’ you monkey :'( …. I fell for this one and it took maybe half an hour of fiddling before I realised there was…
-
Java Document to String
This is a very simple utility function to produce an indented XML document as a String given a Document. It throws a TransformerException if anything drastic goes wrong. [java] import java.io.*; import org.w3c.dom.Document; import javax.xml.transform.*; import javax.xml.transform.dom.DOMSource; … public static String documentToString( Document document ) throws TransformerException { TransformerFactory tFactory = TransformerFactory.newInstance(); Transformer transformer =…
-
Velocity if statement is type sensitive…
Problem I discovered that comparisons in Velocity if statements are type-sensitive the hard way. For example, I am trying to display the ‘selected’ option in a html <SELECT> object. The list of possible values is $list, each is a simple ‘NameValuePair’ value object { String name, String value }. The object I am editing in…