Very nice module!... But there's a pretty serious bug in the 5.x version. I've attached a patch that should fix it.

Steps to reproduce:
1. Enable page caching.
2. Visit a popups-enabled page as an anonymous user (e.g., popups/test)
3. Reload the page (to trigger the cached page view).
4. This results in a white screen of death due to either drupal_add_js() or drupal_add_cs() not being defined.

This is due to the fact that the Drupal 5 version of the module has code in hook_init() which needs to be in hook_menu()... see http://api.drupal.org/api/function/hook_init/5

The attached patch should fix it. Note that most of this patch is just whitespace changes (due to the need to rearrange hook_menu) - the actual change is relatively simple.

CommentFileSizeAuthor
popups_wsod.patch3.63 KBDavid_Rothstein