3v4l.org

run code in 300+ PHP versions simultaneously
<?php function pawshake_notification_add($notification_type, $external_id, $uid = 0, $expire = -1, $variables = array()) { $notification = array( 'created' => REQUEST_TIME, 'notification_type' => $notification_type, 'external_id' => $external_id, 'variables' => $variables, ); // User id is optional. if ($uid) { $notification['uid'] = $uid; } // If no expire is send, default to one day. if ($expire == -1) { $notification['expire'] = REQUEST_TIME + 86400; } print_r($notification); } $expire = time() + 86400 + 86400; pawshake_notification_add('thread_start', $message->thread_id, 0, $expire);

preferences:
29.5 ms | 402 KiB | 5 Q