Push questions
directly into your web pages
or applications

Overview

It takes just a few minutes to integrate a live feed of Woots into any website or app. Alternatively, the section below helps quickly configure a Woot feed and generates automatically the HTML code to insert into your web page.

Plugin control settings

Preview

Copy/paste this configured plugin into your HTML page

Getting started...

You first need to integrate a Wootled plugin code in your HTML page. You need to copy / paste in your page a code similar to the one below. To get the exact code for your need (layout, options, specific woot or feed), configure the plugin above and press refresh to get updated visual and code.

<!-- Wootled Plugin -->

            <div class="wootled-feed center-woot" id="wootled_div"
                data-pluginOptions="float:none, numberofwoots:4"
                data-embedOptions="displaymode:compact, token:O5aNpwsbPaNcSCM">
                <a async href="http://www.wootled.com" style="display:none; margin-bottom:5px">wootled survey woot</a>
                <script async src="https://www.wootled.com/plugin/feed_plugin.js"></script>
            </div>

            

Plugin options

Parameter Type Default Description
Content
feedid string a public feed token
token string a public WOOT token (do not use this if you have already set a feedid)
tokens array an array of valid WOOT public tokens (do not use this if you have already set a feedid)
Position
float enum 'none' set to either 'none', 'bottom-right', or 'bottom-left'. Note that bottom-right and bottom-left will float the div on your HTML page
floatstart string 'min' Either 'min' or 'max'. If you have set your plugin to float in the page, this will determine if it starts minimized (icon of the feed or woot owner), or maximized
displaymode string 'standard' Either 'compact', 'standard', or 'responsive'. It defines the rendering template used to display the woot
bottom string 10px If you have set your plugin to float in the page, this will indicate the relative position of the bottom of the plugin, to your page
edge string 10px If you have set your plugin to float in the page, this will indicate the relative position of the plugin, to the edge of your page (left if float set to 'bottom-left', or right if float set to 'bottom-right')
Authentication
forcelogin boolean false Set it to true to force the user to authenticate before voting.
acceptuserregistration boolean true Set it to false to remove option to self-register.
acceptusersociallogin boolean true Set it to false to remove option to login via social networks.
Misc
showresults boolean true Will force showing the result in place of the answer panel, once the user has voted.

Advanced integration

You do not have to do more than the integration of HTML code in your page to have WOOTs pushed into your web page. However, you can take advantage of the Wootled APIs to control the plugin even more. This however requires coding in Javascript. Here below you find everything to get you going.

First, you need to listen to the Wootled Plugin.

window.addEventListener("Wootled_Event", function(evt) {
        switch(evt) {
            case "wootled_onInitialize":
                <!-- your code here -->
                break;

            default:
                break;
        }
    }, false);   

Plugin APIs

slideNext

slideNext() - slides to the next available Woot in a feed

slidePrev

slidePrev() - slides to the next available Woot in a feed, moving backwards

resize

resize(displaymode szRect ) - Asks the Wootled plugin to resize itself to specific dimensions

  • displaymode - string the display resolution used for the plugin. Either 'compact' (strict 300x250px), 'standard' (default 325x550px), or 'responsive' (adapts to the window size)
  • szRect - object object {w:value, h:value} to set a different width and height to the plugin

socialPost

socialPost(options ) - Asks the Wootled plugin to display a social post dialog

  • options - object An object such as {social:value} where value is a string, either 'facebook' or 'twitter'

logUser

logUser() - Reserved for more complex integration, please ask for more details

Plugin Events

wootled_onInitialized

Event received when the Wootled plugin is initialized and ready to be used

Parameter Type Default Description
uid number a unique user ID set in all communications between plugin and caller
timestamp number a unique timestamp matching the last update of the embeded Woot or Feed
iframe string 'woot' Could be 'woot' or 'feed' depending which part of the plugin is notifying us.

wootled_onFeedLoaded

Event received when a public Feed is fully loaded (the individual WOOTs are not yet loaded at this stage)

Parameter Type Default Description
uid number a unique user ID set in all communications between plugin and caller
iframe string 'feed'

wootled_onWootLoaded

Event received when a WOOT gets loaded in the embed control

Parameter Type Default Description
uid number a unique user ID set in all communications between plugin and caller
iframe string 'woot'
woot.id number The id of the woot that just got loaded
woot.token string The public token of the woot that just got loaded
woot.direction string 'received' The direction of the woot, Either'received', or 'sent' it’s one of yours
woot.status object Extra information about the woot and user seeing it

wootled_onEmpty

Event received when the plugin does not find any WOOT to display

Parameter Type Default Description
uid number a unique user ID set in all communications between plugin and caller
iframe string 'woot'

wootled_onError

Event received when the plugin does not find any WOOT to display

Parameter Type Default Description
uid number a unique user ID set in all communications between plugin and caller
iframe string 'woot' Could be 'woot' or 'feed' depending which part of the plugin is notifying us.
errMsg string The error message in plain (English) text

wootled_onToolbarRefresh

Event received when a WOOT just got displayed, and to indicate any need for prev/next navigation from the container page

Parameter Type Default Description
uid number a unique user ID set in all communications between plugin and caller
iframe string 'woot'

wootled_wasVoted

Event received when a displayed WOOT was already answered by the user

Parameter Type Default Description
uid number a unique user ID set in all communications between plugin and caller
iframe string 'woot'

wootled_onVote

Event received when a WOOT just gets answered

Parameter Type Default Description
uid number a unique user ID set in all communications between plugin and caller
iframe string 'woot'
woot.id number The id of the woot that just got answered
woot.iQuestion number 0 The index of the WOOT question, now generally 0, as WOOT are not multi questions
answers object The answers that the user just voted for