}
switch( $option ) {
- case 'test': // TODO: remove this case (only for testing notifications)
- require_once GLM_MEMBERS_BILLING_PLUGIN_CLASS_PATH . '/notifications.php';
- $Notifications = new GlmNotifications( $this->wpdb, $this->config );
- /**
- * test:
- *
- * Test the notification email.
- * Currently this is just using a hard coded account id of 1.
- * After the test it will call wp_die
- */
-
- $notification_id = filter_var( $_REQUEST['id'], FILTER_VALIDATE_INT );
- if ( $notification_id ) {
- echo '<pre>$notification_id: ' . print_r( $notification_id, true ) . '</pre>';
- $account = 1; // TODO: remove this. It's for testing only
- $noticeReturned = $Notifications->sendEmailNotification( $notification_id, $account );
- // var_dump( $noticeReturned );
- }
- wp_die('Testing here');
- break;
case 'add':
/**