IMAGES, "imagesa" => IMAGES_A, "imagesn" => IMAGES_N, "imagesnc" => IMAGES_NC); if (isset($_GET['ifolder']) && ctype_alnum($_GET['ifolder']) == 1 && isset($folders[$_GET['ifolder']])) { $_GET['ifolder'] = stripinput($_GET['ifolder']); $afolder = $folders[$_GET['ifolder']]; } else { $_GET['ifolder'] = "images"; $afolder = IMAGES; } // List images $image_list = makefilelist($afolder, ".|..", true, "files", "php|js|ico|DS_Store|SVN"); if ($image_list) { $image_count = count($image_list); } else { $image_count = 0; } if (isset($_GET['status'])) { if ($_GET['status'] == "del") { $title = $locale['400']; $message = "".$locale['401'].""; } elseif ($_GET['status'] == "upn") { $title = $locale['420']; $message = "".$locale['425'].""; } elseif ($_GET['status'] == "upy") { $title = $locale['420']; $message = "".stripinput($_GET[

\n".$locale['426'].""; } opentable($title); echo "
".$message."
\n"; closetable(); } if (isset($_GET['del']) && in_array($_GET['del'], $image_list)) { unlink($afolder.stripinput($_GET['del'])); if ($settings['tinymce_enabled'] == 1) { include INCLUDES."buildlist.php"; } redirect(FUSION_SELF.$aidlink."&status=del&ifolder=".$_GET['ifolder']); } elseif (isset($_POST['uploadimage'])) { $error = ""; $image_types = array( ".gif", ".GIF", ".jpeg", ".JPEG", ".jpg", ".JPG", ".png", ".PNG" ); $imgext = strrchr(strtolower($_FILES['myfile']['name']), "."); $imgname = stripfilename(strtolower(substr($_FILES['myfile']['name'], 0, strrpos($_FILES['myfile']['name'], ".")))); $imgsize = $_FILES['myfile']['size']; $imgtemp = $_FILES['myfile']['tmp_name']; if (!in_array($imgext, $image_types)) { redirect(FUSION_SELF.$aidlink."&status=upn&ifolder=".$_GET['ifolder']); } elseif (is_uploaded_file($imgtemp)){ move_uploaded_file($imgtemp, $afolder.$imgname.$imgext); @chmod($afolder.$imgname.$imgext, 0644); if ($settings['tinymce_enabled'] == 1) { include INCLUDES."buildlist.php"; } redirect(FUSION_SELF.$aidlink."&status=upy&ifolder=".$_GET['ifolder']."&img=".$imgname.$imgext); } } else { opentable($locale['420']); echo "
\n"; echo "\n\n"; echo "\n"; echo "\n"; echo "\n\n"; echo "\n"; echo "\n
".$locale['421']."
\n"; echo "
\n
\n"; closetable(); if (isset($_GET['view']) && in_array($_GET['view'], $image_list)) { opentable($locale['440']); echo "

\n"; $image_ext = strrchr($afolder.stripinput($_GET['view']),"."); if (in_array($image_ext, array(".gif",".GIF",".ico",".jpg",".JPG",".jpeg",".JPEG",".png",".PNG"))) { echo "".stripinput($_GET[

\n"; } else { echo $locale['441']."

\n"; } echo "".$locale['442'].""; echo "

\n".$locale['402']."

\n
\n"; closetable(); } else { opentable($locale['460']); echo "\n\n"; echo "\n\n"; if ($image_list) { for ($i=0; $i < $image_count; $i++) { if ($i % 2 == 0) { $row_color = "tbl1"; } else { $row_color = "tbl2"; } echo "\n\n"; echo "\n"; echo "\n"; } if ($settings['tinymce_enabled'] == 1) echo "\n\n\n"; } else { echo "\n\n\n"; } echo "
\n"; echo "".$locale['422']." |\n"; echo "".$locale['423']." |\n"; echo "".$locale['424']." |\n"; echo "".$locale['427']."\n"; echo "
".$image_list[$i]."\n"; echo "".$locale['461']." -\n"; echo "".$locale['462']."
".$locale['464']."
".$locale['463']."
\n"; closetable(); } } require_once THEMES."templates/footer.php"; ?>