TOPIC:

PayPal Form Submit and Google Analytics Event 4 years 11 months ago #180855

  • Topic Author
  • galmala1
  • Offline
  • Fresh Breezer
  • Fresh Breezer
  • Posts: 14
  • Thanks: 0
Hello,

I'm using the following script to track events in Google Analytics while form is submitted:

function ff_PayPalForm_submitted(status, message) {
if (status == 0) {
ga('send', 'event', 'Form Submission', 'paypel button');
ff_switchpage(2);
} else {
alert(message);
}
}

It works great with any other form, but not with the PayPal form. Could you please assist?

Please Log in or Create an account to join the conversation.

PayPal Form Submit and Google Analytics Event 4 years 11 months ago #180856

  • tomeperica's Avatar
  • tomeperica
  • Offline
  • User is blocked
  • User is blocked
  • Posts: 6478
  • Karma: 170
  • Thanks: 674
Hey there,

can you tell me, do you get any error present in Browser Console? Also this name is strange to me paypel button, should be paypal maybe?

Regards,
Tome
Regards,
Tome
==========================================
Need to renew Pro Support?
Buy Here!
==========================================
Satisfied?
Consider a membership!
==========================================
Like us on Facebook
==========================================
Support Crosstec and get ALL EXTENSIONS and professional support for just $5
Here!

Please Log in or Create an account to join the conversation.

PayPal Form Submit and Google Analytics Event 4 years 11 months ago #180861

  • Topic Author
  • galmala1
  • Offline
  • Fresh Breezer
  • Fresh Breezer
  • Posts: 14
  • Thanks: 0
The name is OK. it is a custom name, you can write there whatever you want.
regarding the console, I don't see any related issue. see attached.
Attachments:

Please Log in or Create an account to join the conversation.

PayPal Form Submit and Google Analytics Event 4 years 11 months ago #180863

  • tomeperica's Avatar
  • tomeperica
  • Offline
  • User is blocked
  • User is blocked
  • Posts: 6478
  • Karma: 170
  • Thanks: 674
Can you try to put the code inside your PayPal button Action maybe, something like this(this code is just for example purpose):
function ff_PayPalDonationForm_action(element, action) 
{ 
     switch (action)
     { 
          case 'click': 
          ff_getElementByName('PayPalSelect').value = 'Donation|0|' + ff_getElementByName('donationAmount').value + '|0'; 
          ff_validate_submit(); 
ga('send', 'event', 'Form Submission', 'paypel button');
          break; 
          default:; 
     } // switch 
} // ff_PayPalDonationForm_action 
Let us know the result.

Regards,
Tome
Regards,
Tome
==========================================
Need to renew Pro Support?
Buy Here!
==========================================
Satisfied?
Consider a membership!
==========================================
Like us on Facebook
==========================================
Support Crosstec and get ALL EXTENSIONS and professional support for just $5
Here!

Please Log in or Create an account to join the conversation.

Last edit: Post by tomeperica.

PayPal Form Submit and Google Analytics Event 4 years 11 months ago #180864

  • Topic Author
  • galmala1
  • Offline
  • Fresh Breezer
  • Fresh Breezer
  • Posts: 14
  • Thanks: 0
Thank you.
Will it execute after payment or after click on the submit button?
I would like to track payments, and not clicks on the button, since, after the redirection to PayPal, the user can still exit without completing the payment.

Please Log in or Create an account to join the conversation.

PayPal Form Submit and Google Analytics Event 4 years 11 months ago #180867

  • tomeperica's Avatar
  • tomeperica
  • Offline
  • User is blocked
  • User is blocked
  • Posts: 6478
  • Karma: 170
  • Thanks: 674
Hey there,

can you do a test and see if its working for you?

Regards,
Tome
Regards,
Tome
==========================================
Need to renew Pro Support?
Buy Here!
==========================================
Satisfied?
Consider a membership!
==========================================
Like us on Facebook
==========================================
Support Crosstec and get ALL EXTENSIONS and professional support for just $5
Here!

Please Log in or Create an account to join the conversation.

Time to create page: 0.051 seconds

BreezingForms Pro 1.4.7 for WordPress Released!

Available in the membership section.

September Discount!

Massive discounts on all subscriptions!

Get Your Subscription Here

Quick Links

Downloads

BreezingForms

ContentBuilder

BreezingCommerce

Templates

Documentation

BreezingForms

ContentBuilder

BreezingCommerce

Apprendre BreezingForms (French Community)

Apprendre et maîtriser BreezingForms par des tutoriels et exemples, le tout en français

breezingforms.eddy-vh.com

Questions et réponses sur les forums de l'AFUJ

AFUJ

Special Offer

Summer Sale! All subscriptions at a special price!

Includes prio support, all of our current and future Joomla!® extensions and Joomla!® templates for the duration of your membership.

Get it from here

3rd Party Discount - 25% Off

We help you to keep your costs under control. If you are a new member and purchased a form building tool from a different form vendor, then you'll get a 25% discount on our subscription plans.

How to receive the discount:

Send us a quick email to sales@crosstec.org with a proof of purchase (for example a paypal receipt), await payment instructions and enjoy your membership!