Jan Mi?acky
Forum Replies Created
-
Hi Nastia,
thank you for the information. This is way beyond my skills. I’m curious about one thing – why does this only concern Safari? Don’t the other browsers care and ignore this?Best,
JanHi Nastia,
I glad you could replicate the issue and the dev team will fix it in the future. Happy to help ??Have a great day,
JanHi Adam,
thank you very much. You gave me a 100% clarity on the difference between autofill that Forminator uses and autocomplete attribute.I implemented it as you described for name, e-mail and phone and it works perfectly.
if( $field['element_id'] == 'text-1' ){ if( strpos( $html, $element ) ){ $name = 'name'; return str_replace( $element, $element . ' autocomplete="' . $name . '"', $html ); } } if( $field['element_id'] == 'email-1' ){ if( strpos( $html, $element ) ){ $name = 'email'; return str_replace( $element, $element . ' autocomplete="' . $name . '"', $html ); } } if( $field['element_id'] == 'phone-1' ){ if( strpos( $html, $element ) ){ $name = 'tel'; return str_replace( $element, $element . ' autocomplete="' . $name . '"', $html ); } }
Thanks a lot and have a great day!
Jan- This reply was modified 4 years, 6 months ago by Jan Mi?acky.
Hi Adam,
I’m good, thank you. I hope that you, too.I understand your point. However, I have multiple forms (eg. tours in different cities) and I need to customize Category, Label, etc. for each one. Having this hardcoded is not very convenient.
To show an example how I used to use it with CF7 is mentioned in this post above. On a page where I had the form, I included that script in which I specified what should be sent to Analytics as Category, Label, etc.
This has allowed me to easily customize it for every form and get more detailed data to work with in Analytics.
I was wondering whether I could do the same with Forminator as it doesn’t seem very difficult to make it work.
If it’s still not 100% clear, let me know and I’m very happy to explain it better.
Best regards,
JanHi Nastia,
I’m doing fine, thank you.I put the form on a separate test page here:
https://www.johnnyspraguetours.com/test-forminator-and-recaptcha/I tried it in a private window and the console still shows the errors.
I use the latest Safari 13.1 and the latest macOS 10.15.4.
Best,
Jan- This reply was modified 4 years, 6 months ago by Jan Mi?acky.
Hi Nastia,
I installed the snippet and changed the form id in the PHP file. But I’m lost what I should do next. I clicked through Forminator setting on that particular form and I didn’t find any new available fields or anything I could work with.Can you please explain to me how I should proceed now to add these autocomplete fields to respective input fields on a given form?
Also, how do I add other forms to the PHP file to get the new options? Let’s say 334 and 335?
Thanks a lot for some more guidance, I appreciate it.
Best,
JanHello Kasia,
thank you. I updated the PHP file and added the FB pixel code.In my last comment, I mentioned a script code that I used to add on the page with CF7 form. In addEventListener, there is ‘wpcf7submit’. I tried to replace it with ‘forminator:form:submit:success’.
What I see in my Google Analytics is that after form submission, it records the event but it doesn’t pass on the Event Category, Action and Label name. In Analytics, it only shows are ‘action’, ‘label’, etc.
I need for every form to show in Analytics the parameters I set in addEventListener – for example, ‘Tour’, ‘Send Booking’, etc.
I’m clearly missing something obvious and I hope you can point me in the right direction.
Best,
JanHi Dimitris,
I believe this should not be difficult to implement as it’s basically just rendering parameters to the label HTML tag.Please, keep me posted in this thread.
Thank you!
JanHi Kasia,
I completed all the steps above and see the snippet as Must-use plugin in the administration.With Contact Form 7, I used to have this piece of Javascript on the page with the contact form.
<script type="text/JavaScript"> document.addEventListener( 'wpcf7submit', function( event ) { gtag('send', 'event', 'Tour', 'Send Booking', '', 100); fbq('track', 'Purchase', {currency: 'CZK', value: 100); }, false ); </script>
It was for both Google Analytics and Facebook Pixel.
How do I modify it for Forminator events for both Analytics and Facebook Pixel, please?
Have a nice weekend,
Jan- This reply was modified 4 years, 6 months ago by Jan Mi?acky.
Thanks a lot, Kasia. I’ll give it a try.
Hello Kasia,
thank you. I’d appreciate a bit more guidance. Where do I put this php file? What script do I need to place on a page with the contact form where I state the event details?Please, consider building this in your plugin. I’m sure many users will appreciate an easier way of tracking conversions.
Best regards,
JanForum: Plugins
In reply to: [Contact Form 7] Success message doesn't show upRESOLVED!
The things was hidden in Additional settings in the particular form. I had on_sent_ok action hook there to track submissions with Google Analytics. I use Google Analytics by Yoast plugin and recently I checked in an option Ignore traffic from Administrators. That means that tracking code doesn’t display on the website when you as an admin are logged in. So this JS conflict (couldn’t find the __gaTracker object) resulted in not showing up the success message.
Then on the testing site when I disabled all the plugins including GA by Yoast, there was again no __gaTracker object so that why it failed there as well.
The good news was that the form has been working well for regular site visitors. So this problem was showing up only to me as I was logged in most of the time. I disabled that Ignore traffic from Administrators functionality to see the JS success messages once again.
Hope that will help someone ??
Cheers!Forum: Plugins
In reply to: [Contact Form 7] Success message doesn't show upBuzztone, would it be any help if I gave your access to the WordPress administration? If so, please provide me your e-mail address where I can send details.
Same problem here. Hoping for the update soon, it’s annoying to see this error across the whole administration.
Forum: Plugins
In reply to: [Contact Form 7] Success message doesn't show upHi Robin,
I added your code to Advanced settings but it doesn’t redirect to the success page upon submission. It seems like the form doesn’t know that it’s been sent successfully…