November 2016

How to check code execution time in PHP

To check how match time code execution takes you need to frame checking code with following instructions:

This example result:

Executed for: 8.9997079372406 sek.

How to create symbolic links in Total Commander

Symbolic links in Windows (starts from Vista) can be created using mklink command.

Let’s make a button in Total Commander to create a symbolic link from the selected file:

  1. In a convenient location, for example in Total Commander plug-ins directory c:\TotalCommander\Plugins\ create a batch file mklink.cmd with the following content:

This command creates a symbolic link to the file transferred from the first input parameter and places it in a location from the second input parameter.

  1. Create a button in Total Commander panel by dragging this file to this panel.
  2. Right click on this button and select “Edit …”
    1. In the “Settings” field specify:

Save changes.

%P – path to the file under the cursor in active panel

%N – the name of the file under the cursor in active panel

%T – path to the location, open in a second (non-active) panel

As a result by pressing created button a symbolic link to the file under the cursor in the active Total Commander tab will be created in a location of the inactive tab with the same file name.