The page you are looking at now is at this URL: http://pastoid.com/4l
This paste was last updated on August 27, 2008 at 9:13 pm.
<?php $randomdir = ( Site::out_url( 'theme' ) . '/showcase/' ); $randomhandle = opendir("$randomdir"); $randomfile = array(); while($file = readdir($randomhandle)) { $extension = substr($file, -4); if(($extension == '.php') || ($extension == '.htm') || ($extension == 'html') || ($extension == '.xhtml') ) { $randomfile[] = $file; } } $numfiles = count($randomfile) - 1; $randomnum = rand(0, $numfiles); include("$randomdir" . $randomfile[ $randomnum ]); ?>
Tip: Use Pastoid to shorten URLs with this bookmarklet: Pastoid This