rendered paste bodyHow can I dynamiclly fill <td axis="string" headers="title">FILE_AND_OR_DIRECTORY_NAME_HERE</td> seen below in use :
<tr class="even" style="cursor: pointer;" id="row1">
<td axis="number" headers="order">1</td>
<td axis="string" headers="title">Title 1 </td>
<td axis="date" headers="date" title="2006-02-20">20.2.2006</td>
<td axis="number" headers="num">92</td>
<td axis="sstring" headers="desc">Description 1 </td>
<td axis="date" headers="publish" title="2005-08-01">1.8.2005</td>
<td headers="published">x</td>
</tr>
Using the following php code :
<?php
// Simple Directory Browser Copyright Ga
// reth Lowe 2002 - gareth@quad-drive.org
// Tried to make it as simple as possibl
// e, bear in mind this is one of my first
// php scripts
// To install, place in the root dir of
// your webserver ie "/etc/httpd/home/"
// To navigate run the script specifying
// the directory with the dir function ie :
//
// http://yourserver.net/dir.php?dir=the
// diryouwant
//Declare all variables.
//$rootdir, path to root dir, to stop l3
// 3t hax0rs :P
//$rootdir = "/home/"youraccount"/"htmldir"";
$rootdir = "/home";
//$dirmsg, directory intro message
$dirmsg = "Directory of";
$dir = $_GET['dir'];
$count = 0;
if (eregi("\.", $dir)) {
$dir = ".";
}
if ($dir !== "."){
$prevdir = substr($dir, 0, strpos($dir, "/"));
if ($prevdir == "") {
$prevdir = ".";
}} else {
$prevdir = ".";
}
echo "<p><b>$dirmsg /$dir</b><br><hr size=\"1\"><br><a href=\"dir.php?dir=$prevdir\">Parent Directory</a><br>";
# Blockquote used for displaying purposes
#echo"<blockquote><br>";
$directory = @opendir("$rootdir$dir");
if ($directory == "") {
print "<p><b>Error Reading Directory</b><p>";
} else {
while( $file = readdir( $directory ) )
{
$file_array[] = $file;
}
echo"<ul>";
if ($dir == ".") {
$dir = "";
} else {
$dir = "$dir/";
}
foreach( $file_array as $file )
{
if( $file == ".." || $file == "." )
{
continue;
}
if (eregi("\.", $file)) {
echo"<li><font face=\"Tahoma\" size=\"2\"><a href=\"$dir$file\">$file</a></font></li>";
} else {
echo"<li><font face=\"Tahoma\" size=\"2\"><a href=\"dirTemp.php?dir=$dir$file\">/$file</a></font></li>";
}
$count++;
}
echo"</ul>";
#echo"</blockquote>";
closedir($directory);
}
echo"<hr size=\"1\">There are <b>$count</b> Files In this Directory<br>";
?>