Questions and discussion about developing processes and programming in PHP, JavaScript, web services & REST API.

Moderators: ArturoRobles, ArturoRobles

Forum rules: Please search to see if a question has already asked before creating a new topic. Please don't post the same question in multiple forums.
i have a problem that all the mails sent by any trigger with multi recipients, stay in pending status and not sent to the users, however the mails with single recipient is sending successfully,
here is one of the triggers:-
Code: Select all
$caseId = @@APPLICATION; //UID for current case
if (is_array($users) and count($users) > 0) {
   $emailTo;    //empty string to hold the emails of the participants in case
   foreach ($users as $user) {
      $aUser = userInfo($user['USR_UID']);
      $emailTo .= (empty($emailTo) ? "" : ";" ) . $aUser['mail'];
   PMFSendMessage(@@APPLICATION, '[email protected]', $emailTo,'' , '', 
      "Business plan rejected", 'rejected.html');
the mails in the mail log is in the pending status as below:
Untitledn.png (98.65 KiB) Viewed 1652 times
and as you see in the (TO) field there is no space between mail addresses (may be this is the problem so how to solve it if it is)
- i tried to run the cron file with the code
Code: Select all
"C:\Bitnami\processmaker-\php\php.exe" -f "C:\Bitnami\processmaker-\apps\processmaker\htdocs\workflow\engine\bin\cron.php"
put it telling me that the software is not compatible with the ( windows 8 ) however i can successfully run another php file to calculate the overdue cases with the same code
Code: Select all
"C:\Bitnami\processmaker-\php\php.exe" -f "C:\Bitnami\processmaker-\apps\processmaker\htdocs\workflow\engine\bin\overduecases.php"
please let me know where is the problem
Dear Amos, thank you very much for the solution. This is the exact solution to pending emails when send to more than one recipient.
In fact this mistake is done for most of the examples in Notification sections of the wiki. So it is better to review the sample codes in the wiki and change below lines:
Code: Select all
$emailTo .= (empty($emailTo) ? "" : ";" ) . $aUser['mail'];
with this one:
Code: Select all
$emailTo .= (empty($emailTo) ? "" : "," ) . $aUser['mail'];
as you mention.

The 500 Internal Server Error is the general catch[…]

Really very nice blog information for this one and[…]

This is a long, lengthy and cumbersome process. T[…]

Great read for when on the road. The book provides[…]