Created
January 29, 2015 20:32
-
-
Save 01GOD/befe705d6b729bc7477d to your computer and use it in GitHub Desktop.
Use text in an array on an element. From https://forums.adobe.com/message/6094485
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var info = [ 'your enter your text for slide 1 here', 'your enter your text for slide 2 here', 'your enter your text for slide 3 here', 'your enter your text for slide 4 here', 'your enter your text for slide 5 here' // no comma here - it is the last element of the array. ]; Now you will have to add the code to reach the text in your symbol and this is where it can be tricky, depending what depth it is in. A basic symbol named slide with a text inside named caption would be sym.getSymbol('slide').$('caption').html(info[0]); and it will show element 0 in the array (the first element). The way you call it depends on you. I usually call it the way I showed above on a click event or another kind of event. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment