Advertisement
Dzhubal

Untitled

Aug 19th, 2019
187
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. function dataCollection() {
  2.     if ($) {
  3.         clearInterval(checkJQuery);
  4.         $(document).on('change', '.field.fname input[placeholder="Имя*"]', function() {
  5.             carrotquest.identify([{op: 'update_or_create', key: '$name', value: $(this).val()}]);
  6.         });
  7.         $(document).on('change', '.field.fphone input[placeholder="Телефон*"]', function() {
  8.             carrotquest.identify([{op: 'update_or_create', key: '$phone', value: $(this).val()}]);
  9.         });
  10.         /*$(document).on('change', '', function() {
  11.             carrotquest.identify([{op: 'update_or_create', key: '', value: $(this).val()}]);
  12.         });*/
  13.     };
  14. };
  15. var checkJQuery = setInterval(dataCollection, 500);
  16. setTimeout(function() {
  17.     clearInterval(checkJQuery);
  18. }, 5000);
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement