Use Variable in "Jump to URL/File" trigger

Nov 09, 2012

Hi everyone,

I'm trying to let people share their quiz results on Facebook.

For that, I'm would like to use the "Jump to URL/File" trigger, and uses the Facebook sharer URL.

So far so good.

To make it more interesting, I'm trying to add the user's score in the Facebook post. Something like: "I just got 65% on the quiz. Can you beat my score" type of thing.

To get it going, I've started by a really simple test:

- one blank slide, with a button "share"

- I've also defined a variable called "test". The default value is 5

- the button has a trigger "jump to URL"

- the trigger is set to redirect to http://www.ourdomain.com?id=%test%

When publishing the page for web, in flash, and clicking the button, I am directed to http://www.ourdomain.com?id=%test% instead of http://www.ourdomain.com?id=7

Is that normal or am I doing anything wrong ?

Cheers

Greg

6 Replies
Geert De Rycke

Hi Admin,

I think variable subsitution only works when displaying it as a reference in a textbox.

What you can do, is use JAVA script to do what you want.
You can send variables to JAVA using

var player = GetPlayer();
var email=player.GetVar("MyVariable");

Of course you'll need to add the bits & pieces to upload it onto Facebook...

Cheers

Geert

Steve Flowers

The JavaScript works great in the Flash output. You'll have trouble seeing it locally unless you setup your Flash security settings manager to clear the folder or use the Publish to CD option. But it should work consistently from a Web server.

The JavaScript used to work exclusively within Flash before the first update. JS won't work in the Articulate Mobile Player at the moment. But should work flawlessly in HTML5 and Flash based outputs.

This discussion is closed. You can start a new discussion or contact Articulate Support.