Closed (fixed)
Project:
Views Slideshow
Version:
7.x-3.x-dev
Component:
Code
Priority:
Normal
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
5 Jun 2011 at 17:21 UTC
Updated:
8 Jul 2011 at 06:12 UTC
Jump to comment: Most recent file
Comments
Comment #1
inolen commentedAlso, to add to this, I was over-riding this template to add some jCarousel wrapper elements but that then broke functionality in Drupal.behaviors.viewsSlideshowPagerFields.
When it adds handlers on the pager items in the Drupal.behaviors.viewsSlideshowPagerFields.attach function, it calls:
This breaks when the immediate children aren't the pager items, so to fix it I did:
I'm not sure if this is the best fix, but it got me up and running.
Comment #2
inolen commentedFinal note is that after making the template overrideable, I then only wanted to override it for specific views, so I added:
inside of template_preprocess_views_slideshow_pager_fields(). I also added the same for the field item templates. If anyone would like I could re-roll the original patch, js changes and these hook suggestions into one patch.
Comment #3
milesw commentedJust encountered this and the posted patch worked...after I noticed that the name of the template file changed too. There seems to be remaining issues with other templates though.
Comment #4
inolen commentedThere are definitely other things that don't theme properly, and yes, the template name changed a bit.
I'll re-roll my patch with everything I ended up doing later tonight.
Comment #5
inolen commentedRe-rolled the patch, what it fixes:
- Makes it possible to override what is now views-slideshow-pager-fields.tpl.php (was views-slideshow-pager-field.tpl.php) and views-slideshow-pager-field-item.tpl.php
- Adds suggestions for each of the above .tpl.php based on your view name
- Fixes JS error when the field items aren't the direct children of the main element in views-slideshow-pager-fields.tpl.php. For example, my custom views-slideshow-pager-field.tpl.php looks like so:
Patched against the latest on 7.x-3.x-dev.
Comment #6
milesw commentedThanks, the patch from #5 solves the original issue for me. Hopefully this gets committed soon because this issue makes theming quite difficult. I created a separate issue for the other (less significant) template that's been broken for me: #1191586: Cannot override views-slideshow-controls-text.tpl.php.
Comment #7
redndahead commentedA patch similar to this was committed. None of the javascript was committed and should be added to a new issue with a thorough description of the problem.