What is the correct way to set a page load goal?










3














I have created a goal that should trigger when user visits the 'Booking' page.
In its Rules section, added a new rule as:




where the item ID is equal to Booking




Booking is the name of the booking page. Set item ID to the ID of that page.
Deployed and published the goal. Visited the booking page a few times in different sessions.



After 2 days, I check the Fact_Conversions table and there is no goal triggered for booking.



For the page item, in the Analyze tab, there is a Goals button, where we can select the goals for that page.



Should this be done instead or both?



Using Sitecore 8.2 update 5










share|improve this question




























    3














    I have created a goal that should trigger when user visits the 'Booking' page.
    In its Rules section, added a new rule as:




    where the item ID is equal to Booking




    Booking is the name of the booking page. Set item ID to the ID of that page.
    Deployed and published the goal. Visited the booking page a few times in different sessions.



    After 2 days, I check the Fact_Conversions table and there is no goal triggered for booking.



    For the page item, in the Analyze tab, there is a Goals button, where we can select the goals for that page.



    Should this be done instead or both?



    Using Sitecore 8.2 update 5










    share|improve this question


























      3












      3








      3







      I have created a goal that should trigger when user visits the 'Booking' page.
      In its Rules section, added a new rule as:




      where the item ID is equal to Booking




      Booking is the name of the booking page. Set item ID to the ID of that page.
      Deployed and published the goal. Visited the booking page a few times in different sessions.



      After 2 days, I check the Fact_Conversions table and there is no goal triggered for booking.



      For the page item, in the Analyze tab, there is a Goals button, where we can select the goals for that page.



      Should this be done instead or both?



      Using Sitecore 8.2 update 5










      share|improve this question















      I have created a goal that should trigger when user visits the 'Booking' page.
      In its Rules section, added a new rule as:




      where the item ID is equal to Booking




      Booking is the name of the booking page. Set item ID to the ID of that page.
      Deployed and published the goal. Visited the booking page a few times in different sessions.



      After 2 days, I check the Fact_Conversions table and there is no goal triggered for booking.



      For the page item, in the Analyze tab, there is a Goals button, where we can select the goals for that page.



      Should this be done instead or both?



      Using Sitecore 8.2 update 5







      goals marketing-control-panel






      share|improve this question















      share|improve this question













      share|improve this question




      share|improve this question








      edited Nov 12 at 6:35









      Peter Procházka

      4,5941838




      4,5941838










      asked Nov 12 at 3:53









      Qwerty

      970627




      970627




















          2 Answers
          2






          active

          oldest

          votes


















          5














          Rules are used for something else. You are correct to associate goal instead. Also make sure to deploy goal.



          1) Associate goal with an item



          To associate a goal with an item, from the Sitecore Launchpad, open the Experience Editor or the Content Editor, then navigate to the relevant content item.



          • In the Attributes group, click Goals.

          • In the Experience Editor, this is located on the Optimization tab
            enter image description here

          • In the Content Editor, this is located on the Analyze tab
            enter image description here

          • In the Goals dialog, select the goal that you want to associate with this item and click OK.

          More details can be found in official Sitecore documentation -> https://doc.sitecore.net/sitecore_experience_platform/82/digital_marketing/campaigns/goals__events/associate_a_goal_with_an_item



          2) Deploy goal



          Also make sure that you have deployed goal.



          To deploy the goal, on the Review tab, in the Workflow group, click Deploy on your Goal:



          enter image description here



          More details can be found in Official Sitecore documentation ->
          https://doc.sitecore.net/sitecore_experience_platform/82/digital_marketing/campaigns/goals__events/create_and_deploy_a_goal






          share|improve this answer




























            3














            Since you mention rules, if you do want to introduce rules so that you only trigger goal registration if other conditions are true then you can extend the processItem pipeline defined in Sitecore.Analytics.config to programmatically process a custom rules field on the context item:



            // check if there are any rules set, if not proceed as normal, otherwise do the below

            var context = new RuleContext

            Item = args.Item
            ;

            foreach (Rule<RuleContext> rule in RuleFactory.GetRules<RuleContext>(new args.Item , "RULES FIELD NAME").Rules)

            if (rule.Condition != null)

            var stack = new RuleStack();

            rule.Condition.Evaluate(context, stack);

            if (context.IsAborted)
            continue;

            if ((stack.Count != 0) && ((bool)stack.Pop()))
            // condition met, do something




            And if the conditions on the rules field are satisfied then add the tracking field of the context item to the TrackingParameters property on the ProcessItemArgs:



            args.TrackingParameters.Add(new TrackingField(args.Item["__Tracking"]));


            Your processor will also have access to the current interaction in the pipeline args so you could for example say register a goal conversion on the current page but only if the user has not already registered the goal... or basically anything you can come up with in the rules engine.






            share|improve this answer




















              Your Answer








              StackExchange.ready(function()
              var channelOptions =
              tags: "".split(" "),
              id: "664"
              ;
              initTagRenderer("".split(" "), "".split(" "), channelOptions);

              StackExchange.using("externalEditor", function()
              // Have to fire editor after snippets, if snippets enabled
              if (StackExchange.settings.snippets.snippetsEnabled)
              StackExchange.using("snippets", function()
              createEditor();
              );

              else
              createEditor();

              );

              function createEditor()
              StackExchange.prepareEditor(
              heartbeatType: 'answer',
              autoActivateHeartbeat: false,
              convertImagesToLinks: false,
              noModals: true,
              showLowRepImageUploadWarning: true,
              reputationToPostImages: null,
              bindNavPrevention: true,
              postfix: "",
              imageUploader:
              brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
              contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
              allowUrls: true
              ,
              onDemand: true,
              discardSelector: ".discard-answer"
              ,immediatelyShowMarkdownHelp:true
              );



              );













              draft saved

              draft discarded


















              StackExchange.ready(
              function ()
              StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fsitecore.stackexchange.com%2fquestions%2f14870%2fwhat-is-the-correct-way-to-set-a-page-load-goal%23new-answer', 'question_page');

              );

              Post as a guest















              Required, but never shown

























              2 Answers
              2






              active

              oldest

              votes








              2 Answers
              2






              active

              oldest

              votes









              active

              oldest

              votes






              active

              oldest

              votes









              5














              Rules are used for something else. You are correct to associate goal instead. Also make sure to deploy goal.



              1) Associate goal with an item



              To associate a goal with an item, from the Sitecore Launchpad, open the Experience Editor or the Content Editor, then navigate to the relevant content item.



              • In the Attributes group, click Goals.

              • In the Experience Editor, this is located on the Optimization tab
                enter image description here

              • In the Content Editor, this is located on the Analyze tab
                enter image description here

              • In the Goals dialog, select the goal that you want to associate with this item and click OK.

              More details can be found in official Sitecore documentation -> https://doc.sitecore.net/sitecore_experience_platform/82/digital_marketing/campaigns/goals__events/associate_a_goal_with_an_item



              2) Deploy goal



              Also make sure that you have deployed goal.



              To deploy the goal, on the Review tab, in the Workflow group, click Deploy on your Goal:



              enter image description here



              More details can be found in Official Sitecore documentation ->
              https://doc.sitecore.net/sitecore_experience_platform/82/digital_marketing/campaigns/goals__events/create_and_deploy_a_goal






              share|improve this answer

























                5














                Rules are used for something else. You are correct to associate goal instead. Also make sure to deploy goal.



                1) Associate goal with an item



                To associate a goal with an item, from the Sitecore Launchpad, open the Experience Editor or the Content Editor, then navigate to the relevant content item.



                • In the Attributes group, click Goals.

                • In the Experience Editor, this is located on the Optimization tab
                  enter image description here

                • In the Content Editor, this is located on the Analyze tab
                  enter image description here

                • In the Goals dialog, select the goal that you want to associate with this item and click OK.

                More details can be found in official Sitecore documentation -> https://doc.sitecore.net/sitecore_experience_platform/82/digital_marketing/campaigns/goals__events/associate_a_goal_with_an_item



                2) Deploy goal



                Also make sure that you have deployed goal.



                To deploy the goal, on the Review tab, in the Workflow group, click Deploy on your Goal:



                enter image description here



                More details can be found in Official Sitecore documentation ->
                https://doc.sitecore.net/sitecore_experience_platform/82/digital_marketing/campaigns/goals__events/create_and_deploy_a_goal






                share|improve this answer























                  5












                  5








                  5






                  Rules are used for something else. You are correct to associate goal instead. Also make sure to deploy goal.



                  1) Associate goal with an item



                  To associate a goal with an item, from the Sitecore Launchpad, open the Experience Editor or the Content Editor, then navigate to the relevant content item.



                  • In the Attributes group, click Goals.

                  • In the Experience Editor, this is located on the Optimization tab
                    enter image description here

                  • In the Content Editor, this is located on the Analyze tab
                    enter image description here

                  • In the Goals dialog, select the goal that you want to associate with this item and click OK.

                  More details can be found in official Sitecore documentation -> https://doc.sitecore.net/sitecore_experience_platform/82/digital_marketing/campaigns/goals__events/associate_a_goal_with_an_item



                  2) Deploy goal



                  Also make sure that you have deployed goal.



                  To deploy the goal, on the Review tab, in the Workflow group, click Deploy on your Goal:



                  enter image description here



                  More details can be found in Official Sitecore documentation ->
                  https://doc.sitecore.net/sitecore_experience_platform/82/digital_marketing/campaigns/goals__events/create_and_deploy_a_goal






                  share|improve this answer












                  Rules are used for something else. You are correct to associate goal instead. Also make sure to deploy goal.



                  1) Associate goal with an item



                  To associate a goal with an item, from the Sitecore Launchpad, open the Experience Editor or the Content Editor, then navigate to the relevant content item.



                  • In the Attributes group, click Goals.

                  • In the Experience Editor, this is located on the Optimization tab
                    enter image description here

                  • In the Content Editor, this is located on the Analyze tab
                    enter image description here

                  • In the Goals dialog, select the goal that you want to associate with this item and click OK.

                  More details can be found in official Sitecore documentation -> https://doc.sitecore.net/sitecore_experience_platform/82/digital_marketing/campaigns/goals__events/associate_a_goal_with_an_item



                  2) Deploy goal



                  Also make sure that you have deployed goal.



                  To deploy the goal, on the Review tab, in the Workflow group, click Deploy on your Goal:



                  enter image description here



                  More details can be found in Official Sitecore documentation ->
                  https://doc.sitecore.net/sitecore_experience_platform/82/digital_marketing/campaigns/goals__events/create_and_deploy_a_goal







                  share|improve this answer












                  share|improve this answer



                  share|improve this answer










                  answered Nov 12 at 6:32









                  Peter Procházka

                  4,5941838




                  4,5941838





















                      3














                      Since you mention rules, if you do want to introduce rules so that you only trigger goal registration if other conditions are true then you can extend the processItem pipeline defined in Sitecore.Analytics.config to programmatically process a custom rules field on the context item:



                      // check if there are any rules set, if not proceed as normal, otherwise do the below

                      var context = new RuleContext

                      Item = args.Item
                      ;

                      foreach (Rule<RuleContext> rule in RuleFactory.GetRules<RuleContext>(new args.Item , "RULES FIELD NAME").Rules)

                      if (rule.Condition != null)

                      var stack = new RuleStack();

                      rule.Condition.Evaluate(context, stack);

                      if (context.IsAborted)
                      continue;

                      if ((stack.Count != 0) && ((bool)stack.Pop()))
                      // condition met, do something




                      And if the conditions on the rules field are satisfied then add the tracking field of the context item to the TrackingParameters property on the ProcessItemArgs:



                      args.TrackingParameters.Add(new TrackingField(args.Item["__Tracking"]));


                      Your processor will also have access to the current interaction in the pipeline args so you could for example say register a goal conversion on the current page but only if the user has not already registered the goal... or basically anything you can come up with in the rules engine.






                      share|improve this answer

























                        3














                        Since you mention rules, if you do want to introduce rules so that you only trigger goal registration if other conditions are true then you can extend the processItem pipeline defined in Sitecore.Analytics.config to programmatically process a custom rules field on the context item:



                        // check if there are any rules set, if not proceed as normal, otherwise do the below

                        var context = new RuleContext

                        Item = args.Item
                        ;

                        foreach (Rule<RuleContext> rule in RuleFactory.GetRules<RuleContext>(new args.Item , "RULES FIELD NAME").Rules)

                        if (rule.Condition != null)

                        var stack = new RuleStack();

                        rule.Condition.Evaluate(context, stack);

                        if (context.IsAborted)
                        continue;

                        if ((stack.Count != 0) && ((bool)stack.Pop()))
                        // condition met, do something




                        And if the conditions on the rules field are satisfied then add the tracking field of the context item to the TrackingParameters property on the ProcessItemArgs:



                        args.TrackingParameters.Add(new TrackingField(args.Item["__Tracking"]));


                        Your processor will also have access to the current interaction in the pipeline args so you could for example say register a goal conversion on the current page but only if the user has not already registered the goal... or basically anything you can come up with in the rules engine.






                        share|improve this answer























                          3












                          3








                          3






                          Since you mention rules, if you do want to introduce rules so that you only trigger goal registration if other conditions are true then you can extend the processItem pipeline defined in Sitecore.Analytics.config to programmatically process a custom rules field on the context item:



                          // check if there are any rules set, if not proceed as normal, otherwise do the below

                          var context = new RuleContext

                          Item = args.Item
                          ;

                          foreach (Rule<RuleContext> rule in RuleFactory.GetRules<RuleContext>(new args.Item , "RULES FIELD NAME").Rules)

                          if (rule.Condition != null)

                          var stack = new RuleStack();

                          rule.Condition.Evaluate(context, stack);

                          if (context.IsAborted)
                          continue;

                          if ((stack.Count != 0) && ((bool)stack.Pop()))
                          // condition met, do something




                          And if the conditions on the rules field are satisfied then add the tracking field of the context item to the TrackingParameters property on the ProcessItemArgs:



                          args.TrackingParameters.Add(new TrackingField(args.Item["__Tracking"]));


                          Your processor will also have access to the current interaction in the pipeline args so you could for example say register a goal conversion on the current page but only if the user has not already registered the goal... or basically anything you can come up with in the rules engine.






                          share|improve this answer












                          Since you mention rules, if you do want to introduce rules so that you only trigger goal registration if other conditions are true then you can extend the processItem pipeline defined in Sitecore.Analytics.config to programmatically process a custom rules field on the context item:



                          // check if there are any rules set, if not proceed as normal, otherwise do the below

                          var context = new RuleContext

                          Item = args.Item
                          ;

                          foreach (Rule<RuleContext> rule in RuleFactory.GetRules<RuleContext>(new args.Item , "RULES FIELD NAME").Rules)

                          if (rule.Condition != null)

                          var stack = new RuleStack();

                          rule.Condition.Evaluate(context, stack);

                          if (context.IsAborted)
                          continue;

                          if ((stack.Count != 0) && ((bool)stack.Pop()))
                          // condition met, do something




                          And if the conditions on the rules field are satisfied then add the tracking field of the context item to the TrackingParameters property on the ProcessItemArgs:



                          args.TrackingParameters.Add(new TrackingField(args.Item["__Tracking"]));


                          Your processor will also have access to the current interaction in the pipeline args so you could for example say register a goal conversion on the current page but only if the user has not already registered the goal... or basically anything you can come up with in the rules engine.







                          share|improve this answer












                          share|improve this answer



                          share|improve this answer










                          answered Nov 13 at 12:41









                          Nick Allen

                          1726




                          1726



























                              draft saved

                              draft discarded
















































                              Thanks for contributing an answer to Sitecore Stack Exchange!


                              • Please be sure to answer the question. Provide details and share your research!

                              But avoid


                              • Asking for help, clarification, or responding to other answers.

                              • Making statements based on opinion; back them up with references or personal experience.

                              To learn more, see our tips on writing great answers.





                              Some of your past answers have not been well-received, and you're in danger of being blocked from answering.


                              Please pay close attention to the following guidance:


                              • Please be sure to answer the question. Provide details and share your research!

                              But avoid


                              • Asking for help, clarification, or responding to other answers.

                              • Making statements based on opinion; back them up with references or personal experience.

                              To learn more, see our tips on writing great answers.




                              draft saved


                              draft discarded














                              StackExchange.ready(
                              function ()
                              StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fsitecore.stackexchange.com%2fquestions%2f14870%2fwhat-is-the-correct-way-to-set-a-page-load-goal%23new-answer', 'question_page');

                              );

                              Post as a guest















                              Required, but never shown





















































                              Required, but never shown














                              Required, but never shown












                              Required, but never shown







                              Required, but never shown

































                              Required, but never shown














                              Required, but never shown












                              Required, but never shown







                              Required, but never shown







                              這個網誌中的熱門文章

                              How to read a connectionString WITH PROVIDER in .NET Core?

                              Node.js Script on GitHub Pages or Amazon S3

                              Museum of Modern and Contemporary Art of Trento and Rovereto