Very simple to use.
Calling:[code]$files = dirContents(DIR_PATH, [FILTER, [TYPE]]);[/code]Examples:[code]$files = dirContens("my-dir");
$files is array containing all, both files either directories
$files = dirContens("my-dir", "img[0-9]");
$files is array containing files or directories with ... Read More »
Bayesian Rating is using the Bayesian Average. This is a mathematical term that calculates a rating of an item based on the “believability” of the votes. The greater the certainty based on the number of votes, the more the Bayesian rating approximates the plain, unweighted rating. When there are very few votes, the bayesian rating of an item will be closer to the average rating of all items.
[code]
... Read More »
Could be used across a multitude of languages. What this does is check to see if a variable is set, if it is then the variable gets left alone. If not, you define what it defaults to.
The example takes the variable $myFruit, and if it's already been defined it stays as that fruit. If not, then it is defined as the string "apple".
[code]
1. $myFruit ... Read More »