Welcome to my snippet library!
Hello and welcome to my little snippet collection, here you'll find various code examples and tutorials.
The database currently contains
143 snippets.
Newest snippets
Click here to see a list of all snippets.
-
File download with speed limit (PHP)
This snippet shows you how to limit the download rate of a file download.Added: March 23, 2011 - Tags: network, http, files -
How to do a POST request (PHP)
This example shows how to do a simple POST request to another webserver by using a socket connection.Added: March 23, 2011 - Tags: http, network, connections -
Count files recursive (PHP)
Returns the entire number of files including all child directories.Added: March 11, 2011 - Tags: files, file functions, folder, directory functions -
Safe redirect (PHP)
This little function ensures that visitors are really redirected to a specified URL.Added: March 11, 2011 - Tags: http, helpers, url
-
Simple cURL example (PHP)
A simple example on how to use the cURL module to download a website or any other file.Added: March 11, 2011 - Tags: http, network, example -
Random readable password (PHP)
Generates a random readable password by combining words from a wordlist array.Added: March 11, 2011 - Tags: string functions, random -
Randomize SQL query results (PHP)
There are many ways to get random database results, here I explain two of them.Added: February 11, 2008 - Tags: database functions, random -
Caching for dynamic content (PHP)
I made this snippet to show how to use the Last-Modified and the ETag headerAdded: February 06, 2008 - Tags: caching, http, tutorials