To check how match time code execution takes you need to frame checking code with following instructions:
$StartTime = microtime(true);
// Checking code
// End of checking code
echo "Executed for: ".(microtime(true)-$StartTime)." sek.";
This example result:
Executed for: 8.9997079372406 sek.
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:
- 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.
- Create a button in Total Commander panel by dragging this file to this panel.
- Right click on this button and select “Edit …”
- In the “Settings” field specify:
%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.