here is what i made up.....
chronicle_lister.php
<?php
$val_array_=_array();
$handle_=_opendir('/var/www/coleclan/include/chronicle_data');
while_(false_!==_($files_=_readdir($handle)))_{
array_push($val_array,$files);
}
closedir();
sort($val_array);
foreach($val_array_as_$item){
include_$item;
}
?>
i get the following error when accessing the page....
Fatal error: input in flex scanner failed in /var/www/coleclan/include/chronicle_data on line 1
strange......
what is realy odd is that i had all this in a different directory for testing purposes first.
instead of including the files, i was simpily just echoing to the screen. it worked.
so then i changed the echo code to include code, and moved the file to it's permanant home, changed the path for the opendir() .. upon accessing it, it was broken.
(((2nd EDIT)))
Okay... so for grins... i changed the code back to a listing (echo each filename) and all is good... it is when i use the INCLUDE instead that it is broken.
what is wrong?!
all i want to do is grab the files in a specified folder and include them all in sequence as sorted by filename (as they are named like "12Feb052210", "15Feb051734", etc) ...
this is for the puropse of accomplishing something that resembles a blog... i add a file to the folder, it is included. simple.
help!