Memory Usage Info Snippets


This snippet will check memory and then print initial, final and peak usages.

Have you ever wanted to know how much memory one of your PHP scripts uses when it runs? You might want this information if your script has a memory leak or takes a long time to execute. If that's the case then there's a great built-in function called memory_get_usage, which will display the exact amount of memory being used by your script. This...

C code example for useful macros, functions and tricks

22 January, 2012   

C++ example code for showing how to allocate and free memory

26 June, 2013   

Clear memory, clear console and close all figures.

02 March, 2014   

Delphi code example to get process memory usage

08 January, 2014   

Simple Python IRC bot by Berend.

C code snippet to dynamically create and initialize 4d array

Source code for dynamically create and initialise 4d array

The array is formed dynamically using malloc.

The code includes the CSS which you can add to your stylesheet and please note a class has been added to the table tag.

19 April, 2011   

This snippet shows how to get the thumbnail from exif metadata. This is very useful for generating very fast thumbnails!! I hope many would benefit from this.

06 August, 2012   

Showing how to work with dynamically allocated arrays

10 June, 2013   

A function that returns an array of elements based on DOM element, tag, and class name. For instance, getElementsByClassName(document, 'tr', 'info') will return an array of all "tr" tags under the document node having the "info" class.

In order for this to work, you will need to copy mysqldump.exe and mysql.exe from the MySQL bin Program Files folder into the same directory as your executing PHP script. If you know the direct path to these for your server, you can use those instead.

This function will not recurs subdirectories - it will only return a list of sub folder on the "first" level.

When developing applications that need to operate on files and directories it is a common task to, for example, get the list of all sub-directories for a given directory.

Set the Border style of your main form to bsNone and then use System Parameters Info message to get the SPI_GETWORKAREA value then use Set Bounds to make your Window the correct size.

18 October, 2012   

Meta tags allow you to provide metadata about your HTML pages. Meta tags can be very useful for search engines.

updates (svn up) a working copy and displays the changes