Download & Extend

Prevent looping image groups

Project:Colorbox
Version:7.x-1.x-dev
Component:Miscellaneous
Category:feature request
Priority:normal
Assigned:Unassigned
Status:closed (fixed)

Issue Summary

When reaching the last image of the group there should be no more Next button. The same for the Previous button when reaching the first image.

I think there should be a possibility to set loop:true to loop:false but I couldn't find it.

Is there any other way to get the desired result?

Comments

#1

There is hook_colorbox_settings_alter.
Create custom module and in mymodule.module do this:

<?php
function mymodule_colorbox_settings_alter(&$settings, &$style) {
 
// Disable slideshow looping
 
$settings['loop'] = FALSE;
}
?>

Look at colorbox.api.php for more info.

#2

Status:active» fixed

#3

Status:fixed» closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.

nobody click here