8 Replies Latest reply on Nov 29, 2016 2:11 AM by Ellie Szunko

    Cookies not being displayed

    Ellie Szunko

      We have had new cookies created so we can now monitor last touch. First touch is working as it should and always has - this is a static field. The last touch has been created so it is overwritten each time the UTM value is populated. I've gone to create the last touch hidden values on our web forms but after doing some tests, no last touch values are being pulled through. I'm not very clued up on cookies and the development side of things so any advice would be great as to where to go next / what I'm missing?

       

      Thanks,
      Ellie

        • Re: Cookies not being displayed
          Sanford Whiteman

          You'll need to provide a link to your code.

           

          Most people who try to build their own URL-, referrer-, and cookie-based multitouch attribution scripts do something wrong along the way.

            • Re: Cookies not being displayed
              Sanford Whiteman

              No, I'd need to see the actual JS that is intended to persist data in cookies. If you point to a page on which the code is running, that's fine.

                • Re: Cookies not being displayed
                  Robb Barrett PRD

                  I think he's asking you to extract the code from your page instead of asking him to do it for you.  Where in your code is the script that finds the cookies and stores them, then where is the code that displays them or passes them.

                   

                  If you're not "clued up" on how to use cookies, how to store them, find them and utilize them the question and answer are probably over your head. Not trying to sound rude, but it means discussing javascript and events which not everyone knows well.

                   

                  Are you asking for someone to write your code for you or are you asking to troubleshoot code that's buggy?  If it's the former, that's more of a development consulting engagement. If it's the latter, please post the code and we can help you solve the issue.

                    • Re: Cookies not being displayed
                      Ellie Szunko

                      As I've stated above, no I'm not very "clued up" on how to use cookies Our developers have created this for us, my question was whether I was doing anything wrong in setting up these to capture the fields in our web forms. I certainly wasn’t asking anyone to write the code for me.

                      I’m sure you appreciate not everyone is experts on coding and responses like this certainly don’t help us less experienced reach out for help! I was simply troubleshooting and hoping to pass on any key info to our developers to assist further.

                        • Re: Cookies not being displayed
                          Sanford Whiteman

                          Hi Ellie,

                           

                          To explain what Robb is getting at, it can be frustrating to field questions about code that was presumably contributed by a professional developer without an explanation for why that person her/himself isn't debugging it -- that is, why the question is going to the Community first. 

                           

                          Of course we're here to help, but if someone is contributing production code to your site, even if they admit they don't know what's wrong they should at least provide you with the code so you can present it for review here. There are 77 assets loading on your site that I had to sift through to find out what I assume is the intended behavior.

                           

                          Anyway, from what I can see, you don't have your hidden field sources set up correctly.  Only one of the 2 forms on that page (the modal form) has the hidden fields config'd at all.  But it's looking for cookies named like utm_medium_last__c (i.e. the cookie named the same as the field name) while the stored cookies are actually using shorter names like utm_medium_last. The form needs to be set up to look for the appropriate names.

                          1 of 1 people found this helpful
                          • Re: Cookies not being displayed
                            Robb Barrett PRD

                            My email, upon second reading, conveys a tone I certainly didn't mean to convey so I apologize. I spent a bit of time looking through your site and I wasn't able to find the snippets in the time I had available to help so my intention was more of an attempt to guide on how to ask questions related to fixing code. Sanford Whiteman is extremely knowledgable and apparently has the sleep schedule of a bullfrog and he loves digging around in codeswamps. I was attempting to assist him by trying to isolate the error.

                              • Re: Cookies not being displayed
                                Sanford Whiteman

                                ... apparently has the sleep schedule of a bullfrog and he loves digging around in codeswamps.

                                Less love when stuff is minified with random filenames! But I hate to give up when somewhere in there is buggy code to critique.

                                 

                                I think your "get me out of here" reaction was more reasonable than mine overall... I've gotta get more sleep.