./?'.$urlhash.'
As long as there is not collision, you can shorten it down to 3 characters.'; } elseif (!empty($_GET)) { $urlhash = key($_GET); $hashfolder = substr($urlhash, 0, 2); $hashfile = substr($urlhash, 2); $hashfolderpath = './db/'.$hashfolder; $hashfilepath = $hashfolderpath.'/'.$hashfile; $findfiles = glob($hashfilepath.'*'); if (empty($findfiles)) { $content = 'No files.'; return 1; } elseif (count($findfiles) > 1) { foreach ($findfiles as $file) { $file = str_replace('/', '', substr($file, 5)); $content = './?'.$file.'
'; } } $fullfilepath = current($findfiles); header('Location:'.file_get_contents($fullfilepath)); return 0; } else { $content = '
Enter your URL:
'; } //actual page below ?> Shuri