Team:TU Delft/fb photodisplay
From 2010.igem.org
(Difference between revisions)
(→Parameters) |
|||
(9 intermediate revisions not shown) | |||
Line 1: | Line 1: | ||
<noinclude> | <noinclude> | ||
+ | |||
+ | == Intro == | ||
This is a template page that lists all pictures from a facebook album. | This is a template page that lists all pictures from a facebook album. | ||
- | Either use this template or give credits the TU Delft team! | + | Either use this template or give credits to the TU Delft team! |
If you have questions, contact me: [[User:jcnossen|Jelmer Cnossen]] | If you have questions, contact me: [[User:jcnossen|Jelmer Cnossen]] | ||
+ | |||
+ | == How To Use This == | ||
+ | |||
+ | * Find a facebook album ID to display, using [[Team:TU_Delft/fb_listalbums|fb_listalbums]] | ||
+ | * Put the generated code from fb_listalbums in your wiki, and modify it. | ||
+ | |||
+ | == Parameters == | ||
<br> | <br> | ||
- | <nowiki>{{:Team:TU_Delft/ | + | <nowiki>{{:Team:TU_Delft/fb_photodisplay|album=ID|count=Number of images|css=CSS class}}</nowiki> |
Parameters: | Parameters: | ||
album: Facebook album ID | album: Facebook album ID | ||
count: Number of pictures to display | count: Number of pictures to display | ||
css: CSS class for each image | css: CSS class for each image | ||
+ | callback: Javascript callback function name, callback(container) | ||
</noinclude> | </noinclude> | ||
Line 17: | Line 27: | ||
<div id="fb_scriptload</html>{{{album|135033906513449}}}<html>"></div> | <div id="fb_scriptload</html>{{{album|135033906513449}}}<html>"></div> | ||
<div class="fb_photoscroll" id="photobox</html>{{{album|135033906513449}}}<html>">loading facebook photo's...</div> | <div class="fb_photoscroll" id="photobox</html>{{{album|135033906513449}}}<html>">loading facebook photo's...</div> | ||
- | |||
- | |||
<style> | <style> | ||
Line 63: | Line 71: | ||
} | } | ||
$("#photobox" + albumID).html(html); | $("#photobox" + albumID).html(html); | ||
+ | var callbackname = "</html>{{{callback|}}}<html>"; | ||
+ | if (callbackname != "") | ||
+ | window[callbackname]($("#photobox"+albumID)); | ||
} | } | ||
Latest revision as of 12:22, 19 October 2010
Intro
This is a template page that lists all pictures from a facebook album.
Either use this template or give credits to the TU Delft team! If you have questions, contact me: Jelmer Cnossen
How To Use This
- Find a facebook album ID to display, using fb_listalbums
- Put the generated code from fb_listalbums in your wiki, and modify it.
Parameters
{{:Team:TU_Delft/fb_photodisplay|album=ID|count=Number of images|css=CSS class}} Parameters: album: Facebook album ID count: Number of pictures to display css: CSS class for each image callback: Javascript callback function name, callback(container)
loading facebook photo's...