More From This User Widget

From KickApps API Reference

Jump to: navigation, search

 

Have you ever wondered why we don't have a More From This User list on our media play pages? If you have, the answer is simple, we wanted to let you get creative! Now to help you along in the process, we put together a tutorial and some sample code for you!

To make this happen, first create a widget from the widget studio. For the sake of this example, lets make our widget canvas 300px by 105px. Stlye it however you'd like. This is going to display images, so make sure it is scrollable and easy to view.

Once you've created your widget and you are content with what you're looking at, you can move onto the tough stuff, but considering we've already written the code for you, all thats left is copy and paste with some edits. Which reminds me, be sure to replace all the highlighted terms below with the appropriate values.

<script  type="text/javascript"><br>
if(Ka.Info.PAGE === "pages/mediaPlayPage.jsp" &&  Ka.Info.MEDIATYPE=='PHOTO'){<br>
    $j('<div  id="ka_widgy"></div>').insertAfter('#ka_playPageDetails');<br>
    var photoContributor = $j <br>
    var so = new SWFObject("<a mce_href="http://" href="http://">http://</a>serve.a-widget.com/kickapps/service/getWidgetSwf.kickAction",  "kickWidget_ASID_WIDGET-ID", "WIDTH", "HEIGHT",  "9.0.25", "#000000");
    so.addParam("FlashVars",  "affiliateSiteId=ASID&amp;widgetId=WIDGET-ID&amp;width=WIDTH&amp;height=HEIGHT&amp;mediaURL="  + escape('<a mce_href="http://" href="http://">http://</a>serve.a-widget.com/' + $j('#ka_rssLink  li.ka_rssLink_user a').attr('href')) );<br>
    so.addParam("menu", "false");<br>
    so.addParam("quality", "high");<br>
    so.addParam("allowfullscreen",  "true");<br>
    so.addParam("wmode", "window");<br>
    so.addParam("allowScriptAccess",  "always");<br>
    so.write("ka_widgy");<br>
}<br>
</script><br>
ASID WIDGET-ID WIDTH HEIGHT
The ASID is the affiliate site ID, which can be gotten from your community URL address. The WIDGET-ID is availabe in the widgets embed code. The width of the widget is defined in the Widget Studio when creating the widget. The height of the widget is also defined in the Widget Studio

The code above will either be attached to your pre-existing script files, if you have, or can be placed in the footer of the Global Page Template between <script></script> tags.

Did you enjoy this tutorial? Have questions, comments, or want to submit one of your own? Contact us at support@kickapps.com.