error_reporting(0); include("functions.php"); $h1 = "DJ Mike's Image Maker 2"; $h2 = "Flip/Flop"; if ( isset($_GET[flip_option]) ) { $image = new Imagick($_SESSION[path]); $option = $_GET[flip_option]; if ( ($option == "flip") || ($option == "flipflop")) { foreach ($image as $frame) { $frame->flipImage(); } } if ( ($option == "flop") || ($option == "flipflop")) { foreach ($image as $frame) { $frame->flopImage(); } } $format = strtolower( $image->getimageformat() ); $path = "temp/$ID.$_SESSION[views].$format"; $frames = $image->getNumberImages(); if ( $frames > 1) { $image->writeImages("$path", TRUE); } else { $image->writeImage("$path"); } $_SESSION[path] = $path; header("location:display.php"); exit; } include("top.php"); ?>