Hey there... Just thought I'd post this little script in case anyone wants it. It will read the current directory and display all of your pics/smiles in a formatted table w/ the [IMG] tag code to copy/past into your messages.
PHP Code:
[SIZE=1]
<?php
function flist() {
$website="www.YOURSITE.com/smiles"; //No trailing slashes, no [url]http://[/url]
$dir= getcwd();
$d=dir("$dir");
echo "<div align=\"center\"><table border=\"0\" cellspacing=\"2\" cellpadding=\"0\">";
while (false !== ($entry=$d->read()))
{
$x=is_file($entry);
if($entry[0] !=".")
{
if($entry != $x) {
$path = "$entry";
$file = basename ($path,".php"); // $file is set to "index"
if(($entry != $x)&&($entry != "index.php")) {
echo "<tr><td width=\"184\" align=\"right\" valign=\"middle\"><img src=\"$entry\" border=0></td><td
width=\"516\" align=\"left\" valign=\"middle\"><font size=\"1\" face=\"Verdana\">"."["."img"."]"."http://$website/$entry"."["."/img"."]"."</font></td></tr>";
}}
else {echo "";}}}
echo "</table></div>";
$d->close();
}
flist();
?>[/SIZE]
Just copy/paste this into a plain text file, and save as index.php,
upload to your smiles directory, and point your browser to that page.
Hope you like it.
