GetAllPosts($sTag)) { $iPost = array_rand($aPosts); header('Location: '.$aPosts[$iPost]['url']); exit; } else { echo 'Could not fetch bookmark.'; } ?>