Exceptional Exceptions, Exceptional

Because who doesn't love an exceptional exception every now and then?

Here's an more exceptional one, if you can handle it.

Or, if you're feeling particularly adventurous, try exception-5 for a real challenge.

			
				public function exceptionalException($exception) {
					return "This is an exceptionally exceptionable exception";
				}
			
		

A Very Special Case

When an exception is not just an exception, but a Very Special Case indeed.

			
				public class VerySpecialCase extends Exception {
					public function __construct($message) {
						parent::__construct($message);
						return "Very Special Case: " . $message;
					}
				}
			
		

You can go back to where you started, or try something new for more exceptional exceptions.