Jump to content
View in the app

A better way to browse. Learn more.

The Uniform Server Community

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Exceptions

Featured Replies

Hi, I've got a problem with exceptions in PHP5. When I throw exception, it doesn't propagate through the stack and fails with unhandled exception error, when tryin to catch it somewhere else in the code. Here's example of code, which doesn't work on my Uniform Server, but it works on standard webhosting.

 

<?php

function go($number) {
if ($number == 0) {
	throw new Exception('Zero');
}
}

try {
go(0);
}
catch (Exception $e) {
echo $e->getMessage();
}

?>

 

I've got the latest version of the Uniform Server - 3.5 Apollo.

 

Please can anyone help? Thanks.

The following maybe of interest:

 

From apanel select eAccelerator (left menu)

Now navigate to Actions (main screen) you will see five buttons.

Starting from the top click each button in turn. (Disables Caching and Optimizer)

 

Run your page with the problem code.

 

Well! I ran your test code above and found it works fine, I have no idea what the cause is but suspect that eAccelerator caching could be the culprit! :D

 

All the best

Ric :)

  • Author

Great, it's working now. :D I was very unhappy about it. Hope it won't repeat, but at least I know how to fix it now. Thank you very much! :)

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

Account

Navigation

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.