Just found on heise.de when searching for a tool to recover deleted files from the SD card of my 14 years old daughter. She managed to delete exactly those photos which she intended to keep. Well, I had no copies of these anywhere, as they were only some days old yet.
But then came PhotoRec and saved my life:
The GUI is a bit special for most users but very ok if you feel familiar with shell windows. Quite conveniant. And most important - it recovered more files than Recuva.

On the command line, you may want to execute more than one SQL command
at once. Most hints recommend a batch file to accomplish that, but that
requires an additional file placed somewhere where you may forget it.

You can also fire several queries with the --execute parameter, separated
by semicolon:

If you are using the freeSSHd server and you're experiencing extremely slow connection startups, downloads and uploads from any SFTP client, it is likely that you just need to turn off IP resolving in logfiles. You can disable that in the tab "Logging" > "Resolve IP addresses into hostnames".

It took me quite a few hours to find the cause of various mysterious errors in
Magento's compiled JavaScript files. On most pages these errors did not occur, only
on a specific product review page. Magento was told to leave some .js files away on
this url. So there was a difference between the compiled .js file on that review url
and the other urls. The thing which drived me nuts was: how can I have an error in
JavaScript code which just has less code than some other file which was even
bigger, but had no error?

Take a look at the following two snippets. The first one does not throw an error:

The reason is a silly missing semicolon after the definition of "Product.Config.prototype".
This is only a problem if the immediately following code starts with a parenthesis,
like in the second snippet.

In Magento versions up to the newest v1.9 you will find such prototype definitions without a
semicolon in the folder /js/varien/. Adding a semicolon at the end of
these saved me from getting even more grey hair than I already have.

Just found by accident: When editing a .pas unit, Shift + Ctrl + [ArrowUp or ArrowDown] jumps from procedure declaration to implementation. Very nice if you have large units with several thousands of lines and numerous procedures and functions.

On the root or first level page you probably want to hide a so called breadcrumb menu, as it would be a single word, identically with the page title, looking like a repetition of the page title. All "deeper" page levels should indeed include the complete path.

There is a HMENU.minItems property which looked pretty like what I needed. But that created a dummy item with three dots for missing level items, not what I wanted. So, the trick is to use a conditional block, where the first one is executed on page level 0 and 1, and the second one for all deeper levels:

getTypoLink() doesn't allow you to pass an anchor parameter. So, in order to add an anchor to such a link you just have to add the anchor part to the id parameter:

$this->cObj->getTypoLink('Link Label', '123#myanchor');

$this->cObj->pi_linkToPage('Link Label', '123#myanchor');

$this->cObj->getTypoLink_URL('123#myanchor');

By the way, ever saw what the harmless function class.tslib_content.php:typoLink() does? Have a look just for fun, it's a 300 liner! Feels like Typo3 has a damned considerable amount of workarounds for various special cases and requirements.

Mike has just set up a bugtracker at Google Code for his popular VirtualTree component for Delphi. So, finally, all interested developers can actively participate in enhancing and extending this thing.

HeidiSQL makes extensive use of VirtualTree - as replacement for the normal TTree's and TListView's we had in old days. VirtualTree can display tree-like structures as well as lists, in all colors and flavours you can imagine:

Much more: it minimizes CPU and memory usage by strictly following the virtual paradigm (= just process visible nodes, nothing more, the rest is processed when the users scrolls to it). That means you can create millions of nodes in milliseconds. It has support for drag'n drop, custom cell editors (similar to plugins), images in column headers and cells, tons of useful events, and numerous other things you won't like to miss once you get used to them.

Now, imagine you have several loops and points where any TLocation is added to or substracted from locs. At a later point in your application you need the number of elements in locs. Although that seems totally trivial that is not implemented in Delphi's compiler. The only SET related procedures in Delphi's compiler are Include, Exclude and In - there is no Count method for SETs. Well, you can help out and write your own one, as I discovered here:

Note that if you use the original 4.0 RC1 release your auto update mechanism won't update to this new release as in that older release it was broken (caused by the "M" in "r1901M").

In case you're wondering about the missing RC2 release: That version was created as Subversion tag but found as broken (XP theming was accidently disabled in a previous commit). So I decided to fix that first and - for consistency reasons - created a new version tag.

VirtualTree's inplace editor is the only thing which is (by default) not Unicode enabled in that package. Just found after having a Unicode enabled inplace editor for VirtualTree half implemented: If you have TNT Controls installed, you can activate "TNT support" in your [PathToVirtualTree]\Source\VTConfig.inc :

Internet Explorer 6 has several excuses for not wanting to display certain DIVs or text in DIVs. Most of them arise from the internal hasLayout property which has to forced to -1 (on!) to unhide those HTML parts. I just came around another, very odd reason for why IE6 hides text in certain situations: CSS classnames which interfere with reserved words such as functions. Simple example:

I recently connected my new HD TV to my notebook, to test the DVI-to-HDMI adapter I just bought and various resolutions. I played a bit with different resolutions, started HeidiSQL, moved it to the TV which was used as second desktop. Then, after having plugging off the TV I started HeidiSQL again and saw - nothing! No window visible... HeidiSQL remembered its last window position and started in the area where the TV has previously provided its resolution. So, looked like a bug :)
Started Delphi and found the place where the main window restores its position (Top, Right) and size (Width, Height) from the last session. I discovered the global Screen object has some Monitor* properties - these are:

The most important property to fix the above described bug seemed to be MonitorFromWindow which tells the TMonitor object of the monitor on which the window is being displayed. The great thing about that is: If there is no second monitor plugged in, MonitorFromWindow returns the first TMonitor object available. So it always returns the best fitting monitor number for the given window handle, but never a no longer plugged monitor. Given this TMonitor object you can check if your window is placed within the monitor's resolution:

If the window (that means: the upper left corner) is placed somewhere outside the monitor's resolution, the above code moves its Left + Top properties so there's a minimal rectangle of 80x80 pixels visible in the current monitor. Given this minimum rectangle, the user can now manually move and resize the window.
P.S.: Don't try to Free the TMonitor object afterwards which you got by Screen.MonitorFromWindow - that will lead to an access violation. Most probably MonitorFromWindow returns a reference to that object.

I somehow messed up the file privileges of a rsync'd SVN repository on a Windows server. Most probably it was rsync/cygwin which broke something here. After fiddling around with the folders and files I just zipped the complete directory of the repository, deleted the original files and then unzipped the zipfile again - works perfectly now!
A ZIP file cannot store given privileges of files and folder. But be aware that RAR can, so prefer ZIP!

This took me at least one hour to find out: If you encounter either this error while accessing the backend at /typo3 :
Error in init.php: sitepath not specified correctly
or this error while accessing the frontend:
Cannot find configuration. This file is probably executed from the wrong location.
Just ensure the old PHP arrays like $HTTP_SERVER_VARS are registered. You can do so by adding this PHP flag to your .htaccess :