Index: trunk/wb/include/captcha.php
===================================================================
--- trunk/wb/include/captcha.php	(revision 286)
+++ trunk/wb/include/captcha.php	(revision 287)
@@ -59,10 +59,24 @@
 		imagestring($image, $fnt, $x, $y, substr($_SESSION['captcha'], $i, 1), $darkgray); 
 	}
 	
-	header('Content-type: image/png');
+	// start buffering for size determination
+	ob_start();
+	// add no cache headers
+	header("Expires: Mon, 1 Jan 1990 05:00:00 GMT");
+	header("Last-Modified: " . gmdate("D, d M Y H:i:s") . " GMT");
+	header("Cache-Control: no-store, no-cache, must-revalidate");
+	header("Cache-Control: post-check=0, pre-check=0", false);
+	header("Pragma: no-cache");
+	header("Content-type: image/png");
+	// Make image
 	imagepng($image);
+	// Fetch length
+	header("Content-Length: " . ob_get_length());
+	// send image and turn off buffering
+	ob_end_flush();
+	// clear memory
 	imagedestroy($image);
-	
+
 }
 
 ?>
\ No newline at end of file
