Hi,
my setup On IPN
On Verified:
1- custom code to insert the paypal variables in the db - result OK
2- mail with custom template i put the same paypal variable- result OK
3- custom code with simple html text with message OK VERIFIED - result d'ont show
On Invalid - custom code with simple html text with message - INVALID , please contact admin
On Error - custom code with simple html text with message - ERROR , please contact admin.
Question is:
why the response paypal ipn always returns page ON Invalid
thanks a lot
Cornelio
my setup On IPN
On Verified:
1- custom code to insert the paypal variables in the db - result OK
2- mail with custom template i put the same paypal variable- result OK
3- custom code with simple html text with message OK VERIFIED - result d'ont show
On Invalid - custom code with simple html text with message - INVALID , please contact admin
On Error - custom code with simple html text with message - ERROR , please contact admin.
Question is:
why the response paypal ipn always returns page ON Invalid
thanks a lot
Cornelio
Hi Cornelio,
How do you receive the verified mail ? the ipn event should not be accesses by the browser, its a page which PayPal "only" should access, you should not set the "return url" to that page either.
Best regards,
Max
How do you receive the verified mail ? the ipn event should not be accesses by the browser, its a page which PayPal "only" should access, you should not set the "return url" to that page either.
Best regards,
Max
HI Max,
the problem that makes me crazy is:
-if I enter the code below on PayPalListener VERIFIED with Custom Code
the data correctly is saved to the DB;
..and I enter the code below always on PayPalListener VERIFIED on Email custom template
i receive correctly the email with all the paypal variables.
the question is:
why the Listener is positioned to INVALID?
I send you my account via PM?
Thanks a lot
Best Regards
Cornelio
the problem that makes me crazy is:
-if I enter the code below on PayPalListener VERIFIED with Custom Code
<?php
$id_foto = $_POST['item_name'];
$txn_id = $_POST['txn_id'];
$db = JFactory::getDbo();
$sql = "INSERT INTO `#__cf_payments` (`item_number`,`txn_id`) VALUES ( '" .$id_foto. "','" .$txn_id. "') ";
$db->setQuery($sql);
$db->execute();
?>
the data correctly is saved to the DB;
..and I enter the code below always on PayPalListener VERIFIED on Email custom template
<?php
echo'<div>$_POST: '.print_r($_POST, true).'</div>';
?>
i receive correctly the email with all the paypal variables.
the question is:
why the Listener is positioned to INVALID?
I send you my account via PM?
Thanks a lot
Best Regards
Cornelio
Hi Cornelio,
If these verified actions are processed then how do you know that the "invalid" event is processed ?
Best regards,
Max
If these verified actions are processed then how do you know that the "invalid" event is processed ?
Best regards,
Max
Hi Max,
because if I put this
and I put the same code on custom template email to INVALID but the email arrives empty, without the variable Paypal
Regards
Cornelio
because if I put this
<?php
echo "<font color='red'>
On verified PayPal Listener: VERIFIED.
<br/><br/></font>";
?>
in custom code is not shown while the same code is shown on INVALID
and I put the same code on custom template email to INVALID but the email arrives empty, without the variable Paypal
Regards
Cornelio
Hi Cornelio,
This means that you access the ipn event address using the browser ?
If yes then this is wrong and should not be done, the ipn event should be accesses by PayPal only.
Best regards,
Max
This means that you access the ipn event address using the browser ?
If yes then this is wrong and should not be done, the ipn event should be accesses by PayPal only.
Best regards,
Max
Hi Max,
This is the page after the redirect from paypal
url set to the same on site paypal ipn
Best Regards
Cornelio
This means That You access the event ipn address using the browser?
This is the page after the redirect from paypal
http://www.ieraora.com/demophoto/index.php?option=com_chronoforms5&chronoform=shop_simple_cart&event=ipn
url set to the same on site paypal ipn
Best Regards
Cornelio
Hi Max,
OK now I understand the note:
the problem is that if I remove the Return URL than on the Paypal payment page does not appear the button to return to the store.
Best Regards
Cornelio
OK now I understand the note:
You should NOT add this notify url in the "return url" of the "PayPal Redirect" action, the IPN event is setup to run in the background by a call from PayPal, not using the user's browser.
the problem is that if I remove the Return URL than on the Paypal payment page does not appear the button to return to the store.
Best Regards
Cornelio
Hi Cornelio,
Just add any other url, like a url for an article or create a new form event and add the url to it.
If you download the new Chronoforms v6 and install it (it will install as a new extension) then you can test the demo PayPal form (click new) and check how the PayPal action is configured with multiple events.
Best regards,
Max
Just add any other url, like a url for an article or create a new form event and add the url to it.
If you download the new Chronoforms v6 and install it (it will install as a new extension) then you can test the demo PayPal form (click new) and check how the PayPal action is configured with multiple events.
Best regards,
Max
Great Max!
thank you very much for your patience.
certainly I try the new ChronoForms v6
Best Regards
Cornelio
thank you very much for your patience.
certainly I try the new ChronoForms v6
Best Regards
Cornelio
Hi Max,
PayPal Listener now works fine.
Now in Return URL Redirect PayPal I put a redirect page where I need to call some paypal variables like this
how to do that?
Thank you very much
Cornelio
PayPal Listener now works fine.
Now in Return URL Redirect PayPal I put a redirect page where I need to call some paypal variables like this
$ txn_id = $ _POST ['txn_id'];
how to do that?
Thank you very much
Cornelio
Hi Cornelio,
The return url now points to a form event or an article ? if its a form event then you can use {txn_id} if you are using v5, and {data:txn_id} if you are using v6.
Best regards,
Max
The return url now points to a form event or an article ? if its a form event then you can use {txn_id} if you are using v5, and {data:txn_id} if you are using v6.
Best regards,
Max
Hi Max,
yes,
callback variable I have to use as the query below
Best Regards
Cornelio
yes,
The return url now points to a form event
but your suggestion does not workcallback variable I have to use as the query below
$query->where($db->quoteName('txn_id')." = ".$db->quote($txn_id));
Best Regards
Cornelio
Hi Cornelio,
you mean in PHP ? then you should use
Best regards,
Max
you mean in PHP ? then you should use
$form->data["txn_id"]
Best regards,
Max
Thanks Max,
but it is not what is needed.
screen1 = setting of Paypal Redirect
scrren2 = the page where I want to retrieve this variable.
It does not work if outside IPN?
Best Regards
Cornelio
but it is not what is needed.
screen1 = setting of Paypal Redirect
scrren2 = the page where I want to retrieve this variable.
$ txn_id = $ _POST ['txn_id'];
It does not work if outside IPN?
Best Regards
Cornelio
Hi cornelio,
In the custom code inside "download_after_pay", please use this code:
this will list all the data returned by PayPal on the page after purchase.
Best regards,
Max
In the custom code inside "download_after_pay", please use this code:
<?php
pr($form->data);
this will list all the data returned by PayPal on the page after purchase.
Best regards,
Max
Hi Max,
the result is as follows
Best regards
Cornelio
the result is as follows
Array
(
[option] => com_chronoforms5
[chronoform] => shop_simple_cart
[event] => download_after_pay
)
Best regards
Cornelio
Hi Cornelio,
You get this result after you complete a purchase and get redirected by PayPal back to your website ?
Best regards,
Max
You get this result after you complete a purchase and get redirected by PayPal back to your website ?
Best regards,
Max
Hi Cornelio,
Ok, I didn't expect this, but what do you need to do with the txn_id number ? if you want to store it or send it by email then maybe you can use it in the ipn event instead.
Best regards,
Max
Ok, I didn't expect this, but what do you need to do with the txn_id number ? if you want to store it or send it by email then maybe you can use it in the ipn event instead.
Best regards,
Max
Hi Max,
I said it before in this post. I have to use this variable
email sending and store in the db, if you look at the screen2, are already done.
Best Regards
Cornelio
I said it before in this post. I have to use this variable
$ txn_id
and then reinsert in a query->where
if you want to store it or send it by email then maybe you can use it in the ipn event instead.
email sending and store in the db, if you look at the screen2, are already done.
Best Regards
Cornelio
Hi Max,
I could do this On IPN event but
as I understand it in IPN event we can not stand HTML because the listener works in the background, is it?
Best Regards
Cornelio
I could do this On IPN event but
as I understand it in IPN event we can not stand HTML because the listener works in the background, is it?
Best Regards
Cornelio
Hi Cornelio,
In the ipn you can not "display" any thing to the user, but you can send an data in the email.
If you want to display the txn_id to the user on the website then its not possible in this case, but you can store the data in the database in the ipn, then send the data by email to the user, or let them load it later on the website.
Best regards,
Max
In the ipn you can not "display" any thing to the user, but you can send an data in the email.
If you want to display the txn_id to the user on the website then its not possible in this case, but you can store the data in the database in the ipn, then send the data by email to the user, or let them load it later on the website.
Best regards,
Max
This topic is locked and no more replies can be posted.