$desc = "";
if (strstr($pic, 'http://') != FALSE) {
$album=substr($pic, 0, strrpos($pic, "/"));
$album=substr($album, strrpos($album, "/") + 1)."/";
}
else {
$album=substr($pic, 0, strpos($pic, "/")+1);
$pic=substr($pic, strpos($pic, "/")+1);
}
$fg = fopen ($album."descript.ion","r");
while ($line = fgets ($fg, 1000)) {
$length = strlen ($line);
$cut = strpos ($line, ";");
$data[0]=substr($line,0,$cut);
$data[1]=substr($line,$cut+1);
if ($data[0]==$pic) {
$desc = chop("$data[1]");
}
}
fclose ($fg);
if (!isset($desc)) {$desc="";}
if ($desc=="") {$desc="";}
$trans = array ("\"" => "'", "@" => "
");
$desc = strtr($desc, $trans);
if (strstr($pic, 'http://') != FALSE) {
$album="";
}
?>