Targeting Users

With HelpHero Funnels you can configure your tours to target specific users. This ensures users are shown the most appropriate tours based on their language, device, browser and even custom user properties.

1. Pass User Properties to HelpHero

If you want to target users based on properties that you store on your own database. Then you will need to pass these properties along to HelpHero. If you want to target based on browser, device or language you can skip this step. In the example below we are passing a isAdmin user property to HelpHero.

<script>
  HelpHero.identify('<?php echo get_current_user_id(); ?>', {
    isAdmin: <?php echo get_current_user_is_admin() ? 'true' : 'false'; ?>
  }); 
</script>

Note: this code will vary depending on the server language and frameworks you are using. Please consult with your development team and get in touch if you need more information.

2. Setup a Funnel

Now that HelpHero knows about this new user property you can setup tours to only show if the user is an admin or only if they are not an admin. In the HelpHero editor edit your tour and add a new Funnel Step after the first URL Match.

Now this tour will only run if the user property isAdmin is true.