- <?
- /**
- * The index.php.
- * The main entry for a browser request
- *
- * @package file
- * @filesource
- * @see index.php
- * @copyright (c) http://Finn-Rasmussen.com
- * @license http://Finn-Rasmussen.com/license/ myPHP License conditions
- * @author http://Finn-Rasmussen.com
- * @version 1.9
- * @since 21-oct-2005
- */
-
- /**
- * The required files
- */
- require_once($_SERVER['DOCUMENT_ROOT'].'/initialize.php');
-
- /**
- * Test of File
- */
- print "<h4>Test of File</h4>";
- require_once(HTML_FILE_UTIL_PATH.'/File.php');
- $file = new File('myphp-package.php');
- print '<pre>'.htmlentities($file->getContent())."</pre>\r\n";
-
- /**
- * Test of Dir
- */
- print "<h4>Test of Dir</h4>";
- require_once(HTML_FILE_UTIL_PATH.'/Dir.php');
- $dir = new Dir('..');
- print "cwd = ".$dir->getcwd()."<br />\r\nList dirs ...<br />\r\n";
- $dirs = '';
- $dir->open();
- while($dirs = $dir->read()) {
- print "$dirs<br />\r\n";
- }
- $dir->close();
- ?>