0

HTML5 and custom User Variables

I would need something that enables me to make "HTML pakages" for the users that would work like: if you need a twitter hashtag displayer just add a HTML page in the Presentation Properties menu, which points to http://mysite.com/yourtwitterpackage. But I would like the player to automatically gnereate any user variables the HTML package needs (in the twitter hastag case: a twitterHashtag, number of tweets and time to display each tweet). I know I can say to the user "when adding the html site add also these variables" but it is one more step that can go wrong. The variables the HTML package needs could maybe be defined in the html file itself (eg. in a comment section <!-- BSVARS variable1 {default: value1, access: Private, type: local --> and then when the player parses the html file at display time would add these variables or maybe with the <var> tag or some custom html tags that would not break the page) . Could this be made with an autorun plugin? And maybe then added to the default autorun if enough users find this useful?

I thought this was already implemented with the "Automatically generate user variables for the selected data feeds", but from the documentation I am not really sure this is it (as I red this is linked to the data feeds in the Data Feeds tab).

2 comments

  • 0
    Avatar
    Lyndon

    So, you don't want to use the html widget that you're providing to display the twitter information? What is the html you're providing doing? I"m not sure I understand.

    You want the autorun script to parse the html looking for variables to generate, and then what happens with the variables? Currently, we don't have an example for generating variables in the autorun or plugin. It's not simply creating a variable, the way they currently work. Each variable is actually an array that includes not only the variable value, but different functions depending on how the variable is used. 

  • 0
    Avatar
    Roni Starc

    I'll try to be more clear.

    I am using a html5 widget which fetches tweets by the hashtag. Everything is working. The user can change the hashtag on the players webpage (the uservars page). But to make this work a user, that is adding this twitter widget to his/her presentation has to manually make the twitterHashtag variable in the Presentation properties menu. So if the user forgets to do this or makes a spelling erron in the creation of the variable he/she can not use this feature. So I am looking if there is a way that the player would make (extract) the variables from the html (or any other file) that comes with the widget so that the user would only need to add the link to the html widget to get it's full functionality.

    I am looking for this in a more broad way, not just in regards to this twitter widget of mine. This would enable us to package html widgets for the clients (or maybe even make a "library" of widgets to offer freely or sell). Some widgets could maybe have 10+ variables (let's say a generic menu). This would enable us (developers, integrators etc.) to provide easily usable html widgets. To the client we would just have to say: make an images zone of the dimentions HxW, position it where you like. In the playlist tab pick the big 5, and drag it to the playlist on the right. When it prompts you for a web page reference enter www.somedomain.com/sidgets/menuwidget and you are basically done. Also, this way if a widget gets updated and would need an additional variable it would already be there for the user (so he/she would not need to add the variable in BA and republish everything).

    I scanned through the autorun and saw that you populate the user variables from an xml file at presentation runtime. So I would like to do the same but from a file within the widget "package" (be it either the html file itself or some other file, maybe a "dummy js" file - because the linked js files get are fetched from the web url) at the html widget entry time. Now that I think of it, this could be done in JS if the right bs objects were exposed.

Please sign in to leave a comment.