Loading...
 
Skip to main content

History: Infinite_carousel

Source of version: 28

Copy to clipboard
            {JQ()}$jq(function(){
	$jq('#carousel').infiniteCarousel();
});{JQ}
{DIV(id=>carousel)}
* {IMG(src="http://themes.tiki.org/tiki-download_file.php?fileId=85&display",alt="CandiiClouds",height="265px",width="380px")}{IMG}{TAG(tag=>p)}__Candii Clouds__ [http://themes.tiki.org/tiki-directory_redirect.php?siteId=66|download]{TAG}
* {IMG(src="http://themes.tiki.org/tiki-download_file.php?fileId=86&display",alt="Club Card",height="265px",width="380px")}{IMG}{TAG(tag=>p)}__Club Card__ [http://themes.tiki.org/tiki-directory_redirect.php?siteId=80|download]{TAG}
* {IMG(src="http://themes.tiki.org/tiki-download_file.php?fileId=87&display",alt="absE",height="265px",width="380px")}{IMG}{TAG(tag=>p)}__absE__ [http://themes.tiki.org/tiki-directory_redirect.php?siteId=63|download]{TAG}
* {IMG(src="http://themes.tiki.org/tiki-download_file.php?fileId=88&display",alt="Andreas08",height="265px",width="380px")}{IMG}{TAG(tag=>p)}__Andreas08__ [http://themes.tiki.org/tiki-directory_redirect.php?siteId=64|download]{TAG}
* {IMG(src="http://themes.tiki.org/tiki-download_file.php?fileId=89&display",alt="Andreas09",height="265px",width="380px")}{IMG}{TAG(tag=>p)}__Andreas09__ [http://themes.tiki.org/tiki-directory_redirect.php?siteId=65|download]{TAG}
* {IMG(src="http://themes.tiki.org/tiki-download_file.php?fileId=90&display",alt="Eatlon",height="265px",width="380px")}{IMG}{TAG(tag=>p)}__Eatlon__ [http://themes.tiki.org/tiki-directory_redirect.php?siteId=68|download]{TAG}
* {IMG(src="http://themes.tiki.org/tiki-download_file.php?fileId=91&display",alt="Faulkner",height="265px",width="380px")}{IMG}{TAG(tag=>p)}__Faulkner__ [http://themes.tiki.org/tiki-directory_redirect.php?siteId=69|download]{TAG}
* {IMG(src="http://themes.tiki.org/tiki-download_file.php?fileId=92&display",alt="Green Blog",height="265px",width="380px")}{IMG}{TAG(tag=>p)}__Green Blog__ [http://themes.tiki.org/tiki-directory_redirect.php?siteId=79|download]{TAG}
* {IMG(src="http://themes.tiki.org/tiki-download_file.php?fileId=93&display",alt="Dark Shine",height="265px",width="380px")}{IMG}{TAG(tag=>p)}__Dark Shine__ [http://themes.tiki.org/tiki-directory_redirect.php?siteId=67|download]{TAG}
* {IMG(src="http://themes.tiki.org/tiki-download_file.php?fileId=94&display",alt="Fluid Index",height="265px",width="380px")}{IMG}{TAG(tag=>p)}__Fluid Index__ [http://themes.tiki.org/tiki-directory_redirect.php?siteId=70|download]{TAG}
* {IMG(src="http://themes.tiki.org/tiki-download_file.php?fileId=95&display",alt="Judy",height="265px",width="380px")}{IMG}{TAG(tag=>p)}__Judy (Drupal default theme, Garland)__ [http://themes.tiki.org/tiki-directory_redirect.php?siteId=82|download]{TAG}
* {IMG(src="http://themes.tiki.org/tiki-download_file.php?fileId=98&display",alt="Milky Way",height="265px",width="380px")}{IMG}{TAG(tag=>p)}__Milky Way (Joomla default theme)__ [http://themes.tiki.org/tiki-directory_redirect.php?siteId=83|download]{TAG}
* {IMG(src="http://themes.tiki.org/tiki-download_file.php?fileId=99&display",alt="Smooth",height="265px",width="380px")}{IMG}{TAG(tag=>p)}__Smooth__ [http://themes.tiki.org/tiki-directory_redirect.php?siteId=75|download]{TAG}
* {IMG(src="http://themes.tiki.org/tiki-download_file.php?fileId=100&display",alt="Snow",height="265px",width="380px")}{IMG}{TAG(tag=>p)}__Snow__ [http://themes.tiki.org/tiki-directory_redirect.php?siteId=76|download]{TAG}
* {IMG(src="http://themes.tiki.org/tiki-download_file.php?fileId=101&display",alt="Tikipedia",height="265px",width="380px")}{IMG}{TAG(tag=>p)}__Tikipedia__ [http://themes.tiki.org/tiki-directory_redirect.php?siteId=81|Download]{TAG}
* {IMG(src="http://themes.tiki.org/tiki-download_file.php?fileId=102&display",alt="Underground",height="265px",width="380px")}{IMG}{TAG(tag=>p)}__Underground__ [http://themes.tiki.org/tiki-directory_redirect.php?siteId=78|download]{TAG}
* {IMG(src="http://themes.tiki.org/tiki-download_file.php?fileId=103&display",alt="Twist",height="265px",width="380px")}{IMG}{TAG(tag=>p)}__Twist__ [http://themes.tiki.org/tiki-directory_redirect.php?siteId=77|download]{TAG}
{DIV}

This uses the Infinite Carousel script for JQuery. See [http://www.catchmyfame.com/2009/08/27/jquery-infinite-carousel-plugin-1-2-released/]. When Tiki 5 was released, this script was included as part of the Tiki package. Until then, it had to be downloaded and installed separately.

To make the carousel, there are several steps:
{TABS(name="IC_instructions",tabs="Tiki 6|Tiki 5|Tiki 4")}
# In Tiki 6, Infinite Carousel is included as part of the Tiki package, so there is no need to install the script.
# No modification of code is needed.
# Enable ''JQuery UI'' and ''JQuery Infinite Carousel'' settings at Admin Home > Features > Interface
/////
# In Tiki 5, Infinite Carousel is included as part of the Tiki package, so there is no need to install the script.
# No modification of code is needed.
# Enable ''JQuery UI'' and ''JQuery Infinite Carousel'' settings at Admin Home > Look & Feel > UI Effects
# The necessary CSS still needs to go in the L&F custom html head content, __OR__ it can go in Admin Home > Look & Feel > Miscellaneous > Custom CSS. Example:
** width: 7600px has to be the sum of all widths from all images to be displayed in the infinite carousel.
** {CODE()}
#carousel ul {
	list-style: none;
	width: 7600px;
	margin: 0;
	padding: 0;
	position: relative;
}
#carousel li {
	display:inline;
	float:left;
	background-image: none;
	padding-left: 0;
}
{CODE}
# The initialization script can go in a JQ plugin in the wiki page, before the image divs or at Admin Home > Look & Feel > Miscellaneous > Custom JS. Example:
** {CODE(wrap=>1,colors=>javascript)}{JQ()}$jq(function(){ $jq('#carousel').infiniteCarousel(); });{JQ}{CODE}
+ Parameters can also be set:
** {CODE(wrap=>1,colors=>javascript)}{JQ()}$jq(function(){ $jq('#carousel').infiniteCarousel({ displayThumbnails : 0, textholderHeight : 0, }); });{JQ}{CODE}
+ Here is a list of all the parameters that can be set (from www.catchmyfame.com):
+ {FANCYTABLE(head=__Parameter__|__Description__)}
''transitionSpeed''| the time (in milliseconds) it will take to transition between two images (default 1500)
''displayTime'' |the time (in milliseconds) to display each image (default: 6000)
''textholderHeight''| the height of the caption. This is a fraction of the height of the images. (default: .2)
''displayProgressBar''|Whether or not to display the progress bar (default: 1)
''displayThumbnails''| Whether or not to display the thumbnails for the carousel. (default:  1)
''displayThumbnailNumbers''| Whether or not to automatically place numbers in the thumbnail boxes. (default: 1)
''displayThumbnailBackground''| Whether or not to use the corresponding image as the background for a thumbnail box. (default: 1)
''thumbnailWidth''| the width of each thumbnail box. (default: ’20px’)
''thumbnailHeight''| the height of each thumbnail box. (default: ’20px’)
''thumbnailFontSize''| the font size of the number within the thumbnail box. (default: .7em)
{FANCYTABLE}
+
# The image syntax is added to the page as described below. 
/////
# In Tiki 4, get the script jquery.infinitecarousel.js from the above address.
# modify it by changing all instances of "$" in the file to "$jq". This is because JQuery in Tiki is running in compatibility mode.
# Upload it to your server.
# To initialize the script for use on particular pages, put something like the following in the Look and Feel head custom code. There is an if/then statement that indicates what page the carousel is used on, a link to jquery.infinitecarousel.js, the initialization of the script, and some CSS needed for the carousel div and li items.
{CODE()}
{* Infinite carousel start *}
{if $page eq 'Infinite_carousel' or $page eq 'HomePage' or $page eq 'Tiki 3 Themes'}
<script type="text/javascript" src="lib/jquery/infiniteCarousel/jquery.infinitecarousel.js"></script>
{literal}
<script type="text/javascript">
$jq(function(){
	$jq('#carousel').infiniteCarousel();
});
</script>
<style type="text/css">
#carousel ul {
	list-style: none;
	width: 7600px;
	margin: 0;
	padding: 0;
	position: relative;
}
#carousel li {
	display:inline;
	float:left;
	background-image: none;
	padding-left: 0;
}
</style>
{/literal}
{/if}
{CODE}
{TABS}

Then the wiki page needs something like the following. Note that there is a div with the id "carousel", and an unordered list containing the image and a paragraph for the caption.
{CODE(wrap=1)}
{DIV(id=>carousel)}
* {IMG(src="http://themes.tiki.org/tiki-download_file.php?fileId=85&display",alt="CandiiClouds",height="265px",width="380px")}{IMG}{DIV(type=>p)}__Candii Clouds__ [http://themes.tiki.org/tiki-directory_redirect.php?siteId=66|download]{DIV}
* {IMG(src="http://themes.tiki.org/tiki-download_file.php?fileId=86&display",alt="Club Card",height="265px",width="380px")}{IMG}{DIV(type=>p)}__Club Card__ [http://themes.tiki.org/tiki-directory_redirect.php?siteId=80|download]{DIV}
* {IMG(src="http://themes.tiki.org/tiki-download_file.php?fileId=87&display",alt="absE",height="265px",width="380px")}{IMG}{DIV(type=>p)}__absE__ [http://themes.tiki.org/tiki-directory_redirect.php?siteId=63|download]{DIV}
{DIV}
{CODE}

The procedures described above are for Tiki 4 and Tiki 5. For Tiki 3, there is no Look and Feel "html head" custom code textarea, so templates/header.tpl would have to be edited to add the script.

{REMARKSBOX(type=tip title=Tip)}''Infinite carousel works best when all images are the same dimension. If you're using images of different dimensions and find that some are getting cut off, try using the thinnest image (i.e., largest height/width ratio) as the first image. You may need to experiment to find the best image for avoiding both cutting off images and displaying more than one image at a time.''{REMARKSBOX} 
        

History

Advanced
Information Version
Thu 07 of Jun, 2012 22:30 GMT-0000 Jonny Bradley jQuery Plugin modified by editor. 44
Thu 07 of Jun, 2012 21:47 GMT-0000 Jonny Bradley jQuery Plugin modified by editor. 43
Thu 19 of Apr, 2012 00:04 GMT-0000 Marc Laporte Div mismatch 42
Tue 18 of Oct, 2011 16:03 GMT-0000 Philippe Cloutier attempt to fix errors with images and use the new example 41
Tue 18 of Oct, 2011 16:01 GMT-0000 Philippe Cloutier fix examples using the tiki handler instead (from Jonny's comment) 40
Thu 17 of Mar, 2011 13:09 GMT-0000 Gary Cunningham-Lee 39
Thu 17 of Mar, 2011 13:06 GMT-0000 Gary Cunningham-Lee 38
Thu 17 of Mar, 2011 13:05 GMT-0000 Gary Cunningham-Lee 37
Thu 17 of Mar, 2011 13:04 GMT-0000 Gary Cunningham-Lee 36
Thu 17 of Mar, 2011 13:03 GMT-0000 Gary Cunningham-Lee 35
Thu 17 of Mar, 2011 13:01 GMT-0000 Gary Cunningham-Lee 34
Thu 17 of Mar, 2011 12:55 GMT-0000 Gary Cunningham-Lee div overflow:hidden added, as per bug3753. 33
Thu 17 of Mar, 2011 07:57 GMT-0000 Gary Cunningham-Lee Added statement about "TAG" wikiplugin. 32
Sun 06 of Mar, 2011 10:27 GMT-0000 Bernard Sfez 31
Sun 30 of Jan, 2011 06:58 GMT-0000 lindon 30
Sun 30 of Jan, 2011 05:02 GMT-0000 lindon 29
Tue 04 of Jan, 2011 14:01 GMT-0000 Bernard Sfez Tiki Wiki 6 activation for the script added 28
Tue 04 of Jan, 2011 13:59 GMT-0000 Bernard Sfez 27
Mon 01 of Nov, 2010 16:37 GMT-0000 Xavier de Pedro 26
Mon 01 of Nov, 2010 16:24 GMT-0000 Xavier de Pedro removing extra line breaks inside the carousel code, which seems to conflict with pluginSPLIT in Tiki6 in Opera, Chrome and Safari, because of the parsin order (according to lph tips on irc) 25
Sat 25 of Sep, 2010 17:23 GMT-0000 lindon 24
Sat 25 of Sep, 2010 16:46 GMT-0000 lindon 23
Sat 25 of Sep, 2010 16:45 GMT-0000 lindon added parameters and tip about different size images 22
Sat 25 of Sep, 2010 16:41 GMT-0000 lindon 21
Thu 02 of Sep, 2010 02:03 GMT-0000 Gary Cunningham-Lee Approved plugins so unbreaking JS. 20
Thu 02 of Sep, 2010 01:59 GMT-0000 Gary Cunningham-Lee trying to access the plugin approve button 19
Thu 02 of Sep, 2010 01:56 GMT-0000 Gary Cunningham-Lee tikiwiki to tiki in links. 18
Wed 01 of Sep, 2010 06:09 GMT-0000 lindon 17
Sat 31 of Jul, 2010 13:43 GMT-0000 Gary Cunningham-Lee Angle brackets (in wikitext) got replaced by question marks in an upgrade. 16
Mon 28 of Jun, 2010 18:12 GMT-0000 luciash d' being ?‍♂️ style tag shouldn't be in the HTML body 15
Fri 25 of Jun, 2010 17:25 GMT-0000 Xavier de Pedro adding forgotten html tags 14
Fri 25 of Jun, 2010 17:24 GMT-0000 Xavier de Pedro adding explicit documentation/examples for Tiki5 13
Fri 25 of Jun, 2010 17:16 GMT-0000 Xavier de Pedro updated info regarding tiki5 release 12
Mon 10 of May, 2010 09:45 GMT-0000 jacmoe 11
Thu 18 of Mar, 2010 01:03 GMT-0000 Gary Cunningham-Lee [rollback version 8] 10
Fri 19 of Mar, 2010 15:04 GMT-0000 Gary Cunningham-Lee 9
Thu 18 of Mar, 2010 01:03 GMT-0000 Gary Cunningham-Lee 8
Wed 17 of Mar, 2010 14:07 GMT-0000 Gary Cunningham-Lee Updated with Tiki 5 info. 7
Wed 17 of Mar, 2010 14:04 GMT-0000 Gary Cunningham-Lee 6
Wed 17 of Mar, 2010 13:51 GMT-0000 Gary Cunningham-Lee 5
Mon 08 of Feb, 2010 09:33 GMT-0000 Gary Cunningham-Lee Typo. 4
Mon 08 of Feb, 2010 09:25 GMT-0000 Gary Cunningham-Lee Page created. 3
Tue 01 of Sep, 2009 11:46 GMT-0000 Gary Cunningham-Lee 2
Tue 01 of Sep, 2009 11:25 GMT-0000 Gary Cunningham-Lee 1