Login   Register  
PHP Classes
elePHPant
Icontem

File: ajax/results.php

Recommend this page to a friend!
Stumble It! Stumble It! Bookmark in del.icio.us Bookmark in del.icio.us
  Classes of GrabzIt  >  GrabzIt PHP Library  >  ajax/results.php  >  Download  
File: ajax/results.php
Role: Example script
Content type: text/plain
Description: Retrieve the latest screenshots that have been saved to your server.
Class: GrabzIt PHP Library
Take screenshots of Web pages using GrabzIt
Author: By
Last change:
Date: 1 year ago
Size: 327 bytes
 

Contents

Class file image Download
<?php
$results
glob("../results" DIRECTORY_SEPARATOR "*.*");

if (!
$results)
{
    return;
}

$output = array();
//print each file name
foreach($results as $result)
{
    if (
strpos($result".txt") !== false)
    {
        continue;
    }

    
$output[] = str_replace('../'''$result);
}

echo 
json_encode($output);
?>