Previous/ Next links

Amitaibu - July 22, 2007 - 19:32
Project:Views Slideshow
Version:6.x-2.x-dev
Component:Code
Category:feature request
Priority:normal
Assigned:Unassigned
Status:closed
Description

Hi,
Would be nice to add to the settings, show Previous/ Next buttons. Then show also the number of views. e.g.:

<<Previous | 1 of 10 | next>>

#1

Amitaibu - July 23, 2007 - 11:57

#2

Amitaibu - August 5, 2007 - 18:36
Category:feature request» support request
Status:active» fixed

I guess this will do the job:
http://drupal.org/project/custom_pagers

#3

Anonymous - August 19, 2007 - 18:47
Status:fixed» closed

#4

FlymastaFlex - February 19, 2008 - 14:02
Status:closed» active

i dont think custom pagers will do this.

With Custom Pagers you just can switch through whole nodes no matter what you configure in views.
I am also in need to let the views slideshow control by the user not by timeOut, but i dont get along with the javascript in it.

A method how to change to the next picture in the slideshow just by clicking on the picture would be fine...
I am in urgent need for it.

I had this function in the cck_slideshow, but had problems with IE...

Can anyone help ?

#5

txcrew - February 22, 2008 - 21:59

+1 Also looking for this

txcrew

#6

davea - March 11, 2008 - 02:08

subscribe

#7

jdotti - March 25, 2008 - 13:31

subscribe

#8

gausarts - April 5, 2008 - 21:49

Subscribe. Thanks

#9

Fayna - April 10, 2008 - 05:00

Is this not available with the latest version? It's there on the demo page...

http://drupalhub.org/videos

#10

kirilius - April 10, 2008 - 23:18

Subscribe too!

#11

heronog - April 15, 2008 - 22:15

I hacked something together very quickly. It involves changes to the views_slideshow.js file and a custom theme function.

Here is the custom theme function

/**
*  this displays the main element, where the current slide is shown
*/
function MYTHEME_views_slideshow_main_section($view, $nodes, $type, $items, $item, $div, $hidden_elements) {
  $output .= "\n\n" . '<div id="views_slideshow_main_' . $div . '" class="views_slideshow_main">' . "\n  ";
//   $output .= $item . "\n";
  $output .= $hidden_elements;

//Prev button
$buttons[]="<a id='boton-$div-$i' class='boton-$div' href=javascript:views_slideshow_switch('$div',views_slideshow_prev_div('$div')); >".t('Previous')."</a>";
foreach($items as $i=>$item) {
$buttons[]="<a id='boton-$div-$i' class='boton-$div' href=javascript:views_slideshow_switch('$div',$i); >".($i + 1)."</a>";
}
//Next button
$buttons[]="<a id='boton-$div-$i' class='boton-$div' href=javascript:views_slideshow_switch('$div',views_slideshow_next_div('$div')); >".t('Next')."</a>";


  $output .= theme('item_list',$buttons,NULL,'ul',array('class'=>'lista-slideshow-elements')) . '</div><!--close views_slideshow_main_' . $div . "-->\n\n";
  return $output;
}

The changes to the javascript file are in the attached patch.

Hope someone finds this useful.

AttachmentSize
views_slideshow-prevnextlinks-11.patch 1.33 KB

#12

oleg.bno - December 23, 2008 - 05:07

Hey heronog,

This is very useful but can you provide this hack in .js file not in patch, many people are having problem with deploying patches and me too...

Thanks : )

#13

heronog - January 8, 2009 - 01:04

this is the file i am using. it is OLD now, from the time of my past comment. so use it with care, it may not be up to date (most certainly it isn't)

OLD FILE that USED TO WORK attached

AttachmentSize
views_slideshow.js_.txt 6.54 KB

#14

malancheril - January 21, 2009 - 08:00

Is there any way to get around the pager initiating a page refresh? I created a view slideshow and turned on the pager. But when I click the next page, it refreshes the page.

#15

malancheril - January 21, 2009 - 08:05

Whoops, never mind. Just saw the "use AJAX" setting.

#16

stevekerouac - January 27, 2009 - 22:58

Subscribing.

Excellent module in its simple state but the prev/next buttons would solve 99% of my slideshow needs.

I have had no success using heronog's fix with current releases.

#17

dragonwize - February 2, 2009 - 03:04
Category:support request» feature request

#18

douglas79 - March 13, 2009 - 14:50

Yes this would just be awesome! Subscribing!

#19

gunzip - March 23, 2009 - 10:41

subscribe.

#20

tierecke - April 20, 2009 - 13:54

subscribe.

#21

juroon - April 26, 2009 - 07:04

subscribe.

#22

easp - May 22, 2009 - 21:16

subscribe.

#23

i25 - June 26, 2009 - 19:30

subscribe

#24

trevorkjorlien - July 3, 2009 - 20:12

I just found this on another issue. It adds either Previous/Next buttons, or else a row of numbers as links:

http://drupal.org/node/488682

Just download the zip file, replace the old Views Slideshow, and you'll see a new drop-down in the "style options" called 'Create a Pager'.

It works as I imagined. Though if anybody can find a way to put the pager on the TOP of the slideshow instead of the bottom, that would be cool.

#25

fearlsgroove - July 3, 2009 - 23:06

Please see: #463254: Lots of progress migrating to contrib/plugin architecture, transition to cycle plugin. prev/next pagination included as part of that effort, currently stalled while aaron refactors some.

#26

hypatia7777 - July 5, 2009 - 21:31

subscribe

#27

i25 - July 13, 2009 - 19:36

This pager works great, but the "pause on hover" function seems to not be working after installing these files. Also, is there any provisions for a "pause/play" button as well? Thanks.

#28

NicoDruif - July 15, 2009 - 13:51

subscribing,

I couldnt get the alternative views slideshow zip working, so hoping the pagination functionality will be released soon!

thanx!

#29

pelicani - July 17, 2009 - 20:20

if you theme the slideshow and add custom controls, you can use the functions for next, pause and play.
But there isn't a function for back.
#13 above has a file and if you copy and past the prev function (last one) you will get this result.
Just add is some custom jquery and some custom html for controls and you are in business.
thx heronog for #13
add something like this to a slideshow theme template (views-slideshow.tpl.php)

$(document).ready(function() {
  // These are the divs containing the elements to be displayed in the main div in rotation or mouseover.
  //slideshow_data["1"] = new views_slideshow_data(4, 1000, 1, false, "normal", 0.25);

  // This turns on the timer.
  //views_slideshow_timer("1", true);

  // This sets up the mouseover & mouseout to pause on the main element.
  $("#back").click(
    function() {
     //views_slideshow_timer("1", true);
$("#pause").show();
$("#play").hide();
views_slideshow_switch("1",views_slideshow_prev_div("1"));
    });
  $("#forward").click(
    function() {
     //views_slideshow_timer("1", true);
$("#pause").show();
$("#play").hide();
views_slideshow_switch("1",views_slideshow_next_div("1"));
    });
  $("#play").click(
    function() {
$("#pause").show();
$("#play").hide();
      views_slideshow_resume("1");
    });
  $("#pause").click(
    function() {
$("#pause").hide();
$("#play").show();
      views_slideshow_pause("1");
    });
});//

#30

kirilius - August 21, 2009 - 20:17

It seems that there has been s considerable demand for this feature and there is still no response from the developer?

#31

aaron - August 21, 2009 - 20:25

@kirilius: "the developer" is busy and will get to it when he can -- no one, to my knowledge, is getting paid to work on this module; sorry if we're not responsive enough for you. patches are welcome.

but meanwhile, i see lots of other volunteers are busy on the queue, and i'm highly appreciative of their efforts. does anyone have an updated patch they can submit yet? if not, i'll try to look at the issue next week during my copious amounts of free time.

#32

redndahead - August 21, 2009 - 23:38

Not positive but this patch might have it. #463254: Lots of progress migrating to contrib/plugin architecture, transition to cycle plugin If not I know at least two of us are holding off on new features until that patch is completed.

#33

redndahead - August 25, 2009 - 06:14
Version:5.x-1.x-dev» 6.x-2.x-dev
Status:active» fixed

#558640: More flexible layout This patch brings us closer to the original issue.
#558662: Create ability to add 1 of 4 type pager Will bring us the rest of the way.

I'm going to mark as fixed and we can take care of this issue in the other issues. I think the eventual outcome will be the usage of the tpl.php file in your theme to specify the exact output that you want.

#34

System Message - September 8, 2009 - 06:20
Status:fixed» closed

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

 
 

Drupal is a registered trademark of Dries Buytaert.