Body: <p>Edited 2017 08 01; The problem still exists despite upgrades to WordPress 4.8.0 / CiviCRM 4.7.22.  Recent findings and advice indicate that the issue may be due to the fact that this payment is initiated from a private page, not a public page.  I am investigating a potential solution and will document it here if the solution proves out.</p>
  
  <p>Also, due to changes made over the past two weeks, the IDS messages are no longer appearing in the CiviCRM log, so there is some progress.  </p>
  
  <p>-----END EDIT-----</p>
  
  <p>Using WordPress 4.7.5 and CiviCRM 4.7.19, a membership renewal transaction is entered in CiviCRM and paid via PayPal.  The transaction completes in PayPal and an IPN is sent to CiviCRM.  CiviCRM displays the thank-you page with transaction details, but in CiviCRM the payment remains in Pending status.  The user gets a PayPal payment message, but no CiviCRM receipt. </p>
  
  <p>Checking the CiviCRM log file in the ConfigAndLog folder shows this sequence of events (identifying elements overwritten with XXX): </p>
  
  <pre><code>Jun 05 14:19:25  [info] $IDS Detector Details = Array
  (
      [0] =&gt; Array
          (
              [name] =&gt; cm
              [value] =&gt; {"module":"contribute","contactID":"4563","contributionID":78,"membershipID":"45","contributionPageID":"3"}
              [page] =&gt; /member-renewal-application/?page=CiviCRM&amp;q=civicrm/contribute/transact&amp;_qf_ThankYou_display=1&amp;qfKey=XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX&amp;amt=125.00&amp;cc=USD&amp;cm=%7B%22module%22%3A%22contribute%22%2C%22contactID%22%3A%224563%22%2C%22contributionID%22%3A78%2C%22membershipID%22%3A%2245%22%2C%22contributionPageID%22%3A%223%22%7D&amp;item_name=4563-78-XXX%20Membership&amp;st=Completed&amp;tx=62S51295KD1681941
              [userid] =&gt; XXXX
              [session] =&gt; XXXXXXXXXXXXXXXXXXXXXXXXXX
              [ip] =&gt; XXX.XX.XX.45
              [reaction] =&gt; 0
              [impact] =&gt; 37
          )
  
      [1] =&gt; Array
          (
              [name] =&gt; IDS_request_uri
              [value] =&gt; /member-renewal-application/?page=CiviCRM&amp;q=civicrm/contribute/transact&amp;_qf_ThankYou_display=1&amp;qfKey=XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX&amp;amt=125.00&amp;cc=USD&amp;cm=%7B%22module%22%3A%22contribute%22%2C%22contactID%22%3A%224563%22%2C%22contributionID%22%3A78%2C%22membershipID%22%3A%2245%22%2C%22contributionPageID%22%3A%223%22%7D&amp;item_name=4563-78-XXX%20Membership&amp;st=Completed&amp;tx=62S51295KD1681941
              [page] =&gt; /member-renewal-application/?page=CiviCRM&amp;q=civicrm/contribute/transact&amp;_qf_ThankYou_display=1&amp;qfKey=XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX&amp;amt=125.00&amp;cc=USD&amp;cm=%7B%22module%22%3A%22contribute%22%2C%22contactID%22%3A%224563%22%2C%22contributionID%22%3A78%2C%22membershipID%22%3A%2245%22%2C%22contributionPageID%22%3A%223%22%7D&amp;item_name=4563-78-XXX%20Membership&amp;st=Completed&amp;tx=62S51295KD1681941
              [userid] =&gt; XXXX
              [session] =&gt; XXXXXXXXXXXXXXXXXXXXXXXXXX
              [ip] =&gt; XXX.XX.XX.45
              [reaction] =&gt; 0
              [impact] =&gt; 37
          )
  
  )
  </code></pre>
  
  <p>A network log is available if details would help with analysis.</p>
  
  <p>This looks similar to CRM-18245.  The error is preventing renewals processing which is due this month for the organization.  A fix is needed.  Thanks.</p>
  
  <p>Edit 2017 06 06; 16:00 PDT per @kevin (with extraneous health check records removed).</p>
  
  <p>Network log shows:  </p>
  
  <pre><code>127.0.0.1 - - [05/Jun/2017:14:19:19 -0700] "POST /wp-cron.php?doing_wp_cron=&lt;id1&gt;.&lt;id2&gt; HTTP/1.1" 200 3556 "https://&lt;domain&gt;.org/wp-cron.php?doing_wp_cron=&lt;id1&gt;.&lt;id2&gt;" "WordPress/4.7.5; https://&lt;domain&gt;.org"
  173.0.81.1 - - [05/Jun/2017:14:19:19 -0700] "POST /member-renewal-application/?page=CiviCRM&amp;q=civicrm/payment/ipn/3&amp; HTTP/1.1" 404 42292 "-" "PayPal IPN ( https://www.paypal.com/ipn )"
  76.115.xxx.xxx - - [05/Jun/2017:14:19:25 -0700] "GET /member-renewal-application/?page=CiviCRM&amp;q=civicrm/contribute/transact&amp;_qf_ThankYou_display=1&amp;qfKey=&lt;key&gt;&amp;amt=125.00&amp;cc=USD&amp;cm=%7B%22module%22%3A%22contribute%22%2C%22contactID%22%3A%224563%22%2C%22contributionID%22%3A78%2C%22membershipID%22%3A%2245%22%2C%22contributionPageID%22%3A%223%22%7D&amp;item_name=4563-78-xxx%20Membership&amp;st=Completed&amp;tx=&lt;tx&gt; HTTP/1.1" 200 15436 "https://www.paypal.com/webapps/hermes?token=&lt;token&gt;&amp;useraction=commit&amp;rm=2&amp;mfid=&lt;fid&gt;" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/51.0.2704.79 Safari/537.36 Edge/14.14393"
  76.115.xxx.xxx - - [05/Jun/2017:14:19:25 -0700] "GET /member-renewal-application/?page=CiviCRM&amp;q=civicrm/ajax/l10n-js/en_US&amp;r=YrDT6 HTTP/1.1" 200 6206 "https://&lt;domain&gt;.org/member-renewal-application/?page=CiviCRM&amp;q=civicrm/contribute/transact&amp;_qf_ThankYou_display=1&amp;qfKey=&lt;key&gt;&amp;amt=125.00&amp;cc=USD&amp;cm=%7B%22module%22%3A%22contribute%22%2C%22contactID%22%3A%224563%22%2C%22contributionID%22%3A78%2C%22membershipID%22%3A%2245%22%2C%22contributionPageID%22%3A%223%22%7D&amp;item_name=4563-78-xxx%20Membership&amp;st=Completed&amp;tx=&lt;tx&gt;" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/51.0.2704.79 Safari/537.36 Edge/14.14393"
  173.0.81.1 - - [05/Jun/2017:14:19:32 -0700] "POST /member-renewal-application/?page=CiviCRM&amp;q=civicrm/payment/ipn/3&amp; HTTP/1.1" 404 42292 "-" "PayPal IPN ( https://www.paypal.com/ipn )"
  173.0.81.1 - - [05/Jun/2017:14:19:55 -0700] "POST /member-renewal-application/?page=CiviCRM&amp;q=civicrm/payment/ipn/3&amp; HTTP/1.1" 404 42292 "-" "PayPal IPN ( https://www.paypal.com/ipn )"
  127.0.0.1 - - [05/Jun/2017:14:20:01 -0700] "GET /wp-content/plugins/civicrm/civicrm/bin/cron.php?name=&lt;name&gt;&amp;pass=&lt;pass&gt;&amp;key=&lt;key&gt; HTTP/1.1" 200 3788 "-" "Wget/1.15 (linux-gnu)"
  76.115.xxx.xxx - - [05/Jun/2017:14:20:29 -0700] "POST /wp-admin/admin-ajax.php HTTP/1.1" 200 3883 "https://&lt;domain&gt;.org/wp-admin/admin.php?page=CiviCRM&amp;q=civicrm%2Fadmin%2Fuf%2Fgroup%2Ffield&amp;reset=1&amp;action=browse&amp;gid=15" "Mozilla/5.0 (Windows NT 10.0; WOW64; rv:53.0) Gecko/20100101 Firefox/53.0"
  173.0.81.1 - - [05/Jun/2017:14:20:35 -0700] "POST /member-renewal-application/?page=CiviCRM&amp;q=civicrm/payment/ipn/3&amp; HTTP/1.1" 404 42292 "-" "PayPal IPN ( https://www.paypal.com/ipn )"
  76.115.xxx.xxx - - [05/Jun/2017:14:21:56 -0700] "POST /wp-admin/admin-ajax.php HTTP/1.1" 200 806 "https://&lt;domain&gt;.org/wp-admin/admin.php?page=CiviCRM&amp;q=civicrm%2Fadmin%2Fuf%2Fgroup%2Ffield&amp;reset=1&amp;action=browse&amp;gid=15" "Mozilla/5.0 (Windows NT 10.0; WOW64; rv:53.0) Gecko/20100101 Firefox/53.0"
  173.0.81.1 - - [05/Jun/2017:14:21:58 -0700] "POST /member-renewal-application/?page=CiviCRM&amp;q=civicrm/payment/ipn/3&amp; HTTP/1.1" 404 42292 "-" "PayPal IPN ( https://www.paypal.com/ipn )" 
  </code></pre>
  
  <p>@Kevin, others, this is the network activity log around the time of the ConfigAndLog entry.  Let me know if it sheds any light on the error.  I do see the IPN messages, note they appear before and after the time of interest. There were earlier failed transactions that are causing this.  Looking at PayPal, the IPN log shows a number of transactions in retry.  </p>
  
Comments.ContentLicense: CC BY-SA 3.0
Comments.CreationDate: 2017-06-05T23:34:07.287Z
Comments.Text: anything before or after that block of data?   The IPN gets a bit after the transaction is complete (sometimes almost immediately, sometimes there is a lag).  You should see the transaction in your web server logs.   Check there.   We have many many sites with WP and CiviCRM using PayPal.  Sometimes it is tough to find the failure, but if we can see the IPN transaction in the web server logs it helps.
Comments.UserDisplayName: Kevin Cristiano
Comments.ContentLicense: CC BY-SA 3.0
Comments.CreationDate: 2017-07-28T18:07:30.237Z
Comments.Text: As of 2017 07 28, this is still unresolved.  I'll try again and see if I can close this one out...
Comments.UserDisplayName: dvhirst
Tags: <wordpress><contributions><paypal><receipts><failure>
Title: Why don't contributions paid via a private page, using PayPal, complete and send receipts?
ThreadText: # Why don't contributions paid via a private page, using PayPal, complete and send receipts?
  
  (Asked by: username_0 on 2017-06-05)
  
  Edited 2017 08 01; The problem still exists despite upgrades to WordPress 4.8.0 / CiviCRM 4.7.22.  Recent findings and advice indicate that the issue may be due to the fact that this payment is initiated from a private page, not a public page.  I am investigating a potential solution and will document it here if the solution proves out.
  Also, due to changes made over the past two weeks, the IDS messages are no longer appearing in the CiviCRM log, so there is some progress.  
  -----END EDIT-----
  Using WordPress 4.7.5 and CiviCRM 4.7.19, a membership renewal transaction is entered in CiviCRM and paid via PayPal.  The transaction completes in PayPal and an IPN is sent to CiviCRM.  CiviCRM displays the thank-you page with transaction details, but in CiviCRM the payment remains in Pending status.  The user gets a PayPal payment message, but no CiviCRM receipt. 
  Checking the CiviCRM log file in the ConfigAndLog folder shows this sequence of events (identifying elements overwritten with XXX): 
  Jun 05 14:19:25  [info] $IDS Detector Details = Array
  (
      [0] => Array
          (
              [name] => cm
              [value] => {"module":"contribute","contactID":"4563","contributionID":78,"membershipID":"45","contributionPageID":"3"}
              [page] => /member-renewal-application/?page=CiviCRM&q=civicrm/contribute/transact&_qf_ThankYou_display=1&qfKey=XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX&amt=125.00&cc=USD&cm=%7B%22module%22%3A%22contribute%22%2C%22contactID%22%3A%224563%22%2C%22contributionID%22%3A78%2C%22membershipID%22%3A%2245%22%2C%22contributionPageID%22%3A%223%22%7D&item_name=4563-78-XXX%20Membership&st=Completed&tx=62S51295KD1681941
              [userid] => XXXX
              [session] => XXXXXXXXXXXXXXXXXXXXXXXXXX
              [ip] => XXX.XX.XX.45
              [reaction] => 0
              [impact] => 37
          )
  
      [1] => Array
          (
              [name] => IDS_request_uri
              [value] => /member-renewal-application/?page=CiviCRM&q=civicrm/contribute/transact&_qf_ThankYou_display=1&qfKey=XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX&amt=125.00&cc=USD&cm=%7B%22module%22%3A%22contribute%22%2C%22contactID%22%3A%224563%22%2C%22contributionID%22%3A78%2C%22membershipID%22%3A%2245%22%2C%22contributionPageID%22%3A%223%22%7D&item_name=4563-78-XXX%20Membership&st=Completed&tx=62S51295KD1681941
              [page] => /member-renewal-application/?page=CiviCRM&q=civicrm/contribute/transact&_qf_ThankYou_display=1&qfKey=XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX&amt=125.00&cc=USD&cm=%7B%22module%22%3A%22contribute%22%2C%22contactID%22%3A%224563%22%2C%22contributionID%22%3A78%2C%22membershipID%22%3A%2245%22%2C%22contributionPageID%22%3A%223%22%7D&item_name=4563-78-XXX%20Membership&st=Completed&tx=62S51295KD1681941
              [userid] => XXXX
              [session] => XXXXXXXXXXXXXXXXXXXXXXXXXX
              [ip] => XXX.XX.XX.45
              [reaction] => 0
              [impact] => 37
          )
  
  )
  
  A network log is available if details would help with analysis.
  This looks similar to CRM-18245.  The error is preventing renewals processing which is due this month for the organization.  A fix is needed.  Thanks.
  Edit 2017 06 06; 16:00 PDT per @kevin (with extraneous health check records removed).
  Network log shows:  
  127.0.0.1 - - [05/Jun/2017:14:19:19 -0700] "POST /wp-cron.php?doing_wp_cron=. HTTP/1.1" 200 3556 "https://.org/wp-cron.php?doing_wp_cron=." "WordPress/4.7.5; https://.org"
  173.0.81.1 - - [05/Jun/2017:14:19:19 -0700] "POST /member-renewal-application/?page=CiviCRM&q=civicrm/payment/ipn/3& HTTP/1.1" 404 42292 "-" "PayPal IPN ( https://www.paypal.com/ipn )"
  76.115.xxx.xxx - - [05/Jun/2017:14:19:25 -0700] "GET /member-renewal-application/?page=CiviCRM&q=civicrm/contribute/transact&_qf_ThankYou_display=1&qfKey=&amt=125.00&cc=USD&cm=%7B%22module%22%3A%22contribute%22%2C%22contactID%22%3A%224563%22%2C%22contributionID%22%3A78%2C%22membershipID%22%3A%2245%22%2C%22contributionPageID%22%3A%223%22%7D&item_name=4563-78-xxx%20Membership&st=Completed&tx= HTTP/1.1" 200 15436 "https://www.paypal.com/webapps/hermes?token=&useraction=commit&rm=2&mfid=" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/51.0.2704.79 Safari/537.36 Edge/14.14393"
  76.115.xxx.xxx - - [05/Jun/2017:14:19:25 -0700] "GET /member-renewal-application/?page=CiviCRM&q=civicrm/ajax/l10n-js/en_US&r=YrDT6 HTTP/1.1" 200 6206 "https://.org/member-renewal-application/?page=CiviCRM&q=civicrm/contribute/transact&_qf_ThankYou_display=1&qfKey=&amt=125.00&cc=USD&cm=%7B%22module%22%3A%22contribute%22%2C%22contactID%22%3A%224563%22%2C%22contributionID%22%3A78%2C%22membershipID%22%3A%2245%22%2C%22contributionPageID%22%3A%223%22%7D&item_name=4563-78-xxx%20Membership&st=Completed&tx=" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/51.0.2704.79 Safari/537.36 Edge/14.14393"
  173.0.81.1 - - [05/Jun/2017:14:19:32 -0700] "POST /member-renewal-application/?page=CiviCRM&q=civicrm/payment/ipn/3& HTTP/1.1" 404 42292 "-" "PayPal IPN ( https://www.paypal.com/ipn )"
  173.0.81.1 - - [05/Jun/2017:14:19:55 -0700] "POST /member-renewal-application/?page=CiviCRM&q=civicrm/payment/ipn/3& HTTP/1.1" 404 42292 "-" "PayPal IPN ( https://www.paypal.com/ipn )"
  127.0.0.1 - - [05/Jun/2017:14:20:01 -0700] "GET /wp-content/plugins/civicrm/civicrm/bin/cron.php?name=&pass=&key= HTTP/1.1" 200 3788 "-" "Wget/1.15 (linux-gnu)"
  76.115.xxx.xxx - - [05/Jun/2017:14:20:29 -0700] "POST /wp-admin/admin-ajax.php HTTP/1.1" 200 3883 "https://.org/wp-admin/admin.php?page=CiviCRM&q=civicrm%2Fadmin%2Fuf%2Fgroup%2Ffield&reset=1&action=browse&gid=15" "Mozilla/5.0 (Windows NT 10.0; WOW64; rv:53.0) Gecko/20100101 Firefox/53.0"
  173.0.81.1 - - [05/Jun/2017:14:20:35 -0700] "POST /member-renewal-application/?page=CiviCRM&q=civicrm/payment/ipn/3& HTTP/1.1" 404 42292 "-" "PayPal IPN ( https://www.paypal.com/ipn )"
  76.115.xxx.xxx - - [05/Jun/2017:14:21:56 -0700] "POST /wp-admin/admin-ajax.php HTTP/1.1" 200 806 "https://.org/wp-admin/admin.php?page=CiviCRM&q=civicrm%2Fadmin%2Fuf%2Fgroup%2Ffield&reset=1&action=browse&gid=15" "Mozilla/5.0 (Windows NT 10.0; WOW64; rv:53.0) Gecko/20100101 Firefox/53.0"
  173.0.81.1 - - [05/Jun/2017:14:21:58 -0700] "POST /member-renewal-application/?page=CiviCRM&q=civicrm/payment/ipn/3& HTTP/1.1" 404 42292 "-" "PayPal IPN ( https://www.paypal.com/ipn )" 
  
  @Kevin, others, this is the network activity log around the time of the ConfigAndLog entry.  Let me know if it sheds any light on the error.  I do see the IPN messages, note they appear before and after the time of interest. There were earlier failed transactions that are causing this.  Looking at PayPal, the IPN log shows a number of transactions in retry.
  
  **Tags:** wordpress, contributions, paypal, receipts, failure
  
  > **Comments:**
  > **username_1**: anything before or after that block of data?   The IPN gets a bit after the transaction is complete (sometimes almost immediately, sometimes there is a lag).  You should see the transaction in your web server logs.   Check there.   We have many many sites with WP and CiviCRM using PayPal.  Sometimes it is tough to find the failure, but if we can see the IPN transaction in the web server logs it helps.  
  > **username_0**: As of 2017 07 28, this is still unresolved.  I'll try again and see if I can close this one out...  
  
  ---
  
  ## 0 answers
  
  