Example #1
0
<?php

require_once 'TestVSMGFileHelper.php';
require_once 'TestVSMGImageHelper.php';
TestVSMGFileHelper::run();
TestVSMGImageHelper::run();
$username = '******';
$password = '******';
$database = 'modx';
// Setup a quick html file
$all_images = VSMGFileHelper::getImagePaths("../test/images", TRUE);
$gallery = new VSMGGallery($all_images, $username, $password, $database);
$gallery_html = $gallery->getThumbnailsHTML();
$ind_file = "index-test.html";
$fh = fopen($ind_file, 'w') or die("Erro opening file");
$html = "<html>\n" . '	<link rel="stylesheet" href="../css/vsmg.css" type="text/css"/>' . $gallery_html . "</html>\n";
fwrite($fh, $html);
fclose($fh);
Example #2
0
 static function run()
 {
     TestVSMGFileHelper::setup();
     TestVSMGFileHelper::testGetImagePaths();
     TestVSMGFileHelper::teardown();
 }