hash urls - go to slide
feature request.
Good idea. Any preference on how to handle more than one slider per page?
good question.
If a slide has an id - then the hash could match the id, so only a slideshow with that slide as an id would be affected.
would this also scroll the page to the top of the slideshow element?
@dan-diaz , I would think not, as you could easily add that yourself with jquery url param checking.
I think it would work ?slide=mySlideID If the slider has autoplay, it would pause autoplay for that slider.
Then if you want scroll, you can scroll to the div. (Maybe Ken will add the slide id to the data object). Additionally, you could restart the slideshow if autoplay was paused once the slideshow was interacted with, or after the scroll, etc.
In my mind, these are things that are outside of the slider (as the author can't account for every scenario/use-case)
I want to add this, but I want to be careful about how. I want to: A. Not add too much weight. B. Not cause multi-slider conflicts C. Make it as flexible as possible
So @jasonday, your saying that , in a use case, if you hit #?slide=#thisSlide and #thisSlide is in the second carousel on the page, the plugin would pause autoplay, and jump to that slide, then not resume until the slideshow was interacted with?
@kenwheeler
I see the plugin only doing the following:
hash-url go to slide (not scroll to slider, just ensure that the slide is the active slide) pause slideshow if is autoplay (if you don't pause, then the hash-url would be useless)
Anything else such as scroll, etc. can be handled with code outside of the plugin (developer can use the api and reenable autoplay, etc. )
Ok, I'll shoot for 1.3.5 with this.
http://owlcarousel.owlgraphic.com/demos/urlhashnav.html
they add an data attribut data-hash. Example: data-hash="yourhashname"
Was this added/introduced officially? It's still 'open' so I'm presuming not, but this would be a great feature to have at this point.
This feature would be really useful. :+1: It's the one thing that Slick doesn't have that Flex Slider does and I'd really prefer to use Slick! @kenwheeler Where in the implementation would you say you are? I'm willing to help out and submit a PR if there's some in-dev code that I could help with.
:+1: I would also appreciate this feature - especially with the posiibility to access multiple sliders on the page for example by id/class of the slider
I have created this feature. I can submit the code if you would like... Let me know. I didn't even think to check the forums for this. LMAO!
Just wondering if there has been any update about this feature. Yea would find it really useful too. @astericky Is there anyway I could check out your code for this. Thanks a million.
just a thought: If it's set via a # then I could not also send the user down to a anchor... where as with a querystring I can send the user to an anchor and change a slider. - It should also be namespaced so e-stores and blogs and such don't have problems.
mySite.com/#myTitleAnchor?slick-myCarousel=0&slick-myOtherCarousel=3
I also don't think it should interfere with pausing autoplays and such... that can easily be done with onInit() per-implementation
Honestly, though, I think good documentation on the examples page showing how to implement this in the onInit() call could be sufficient without bloating everybody's code... - my two cents :smile:
@astericky can you post the code?
@astericky lets see what youre working with
Ok Ill send it along.
Chris Sanders Front-End Engineer Sent from my iPhone
On Dec 14, 2014, at 8:07 AM, Ken Wheeler [email protected] wrote:
@astericky lets see what youre working with
— Reply to this email directly or view it on GitHub.
Im at a fb lunch will send after. I found the code I used. I didn't add to slick itself but I am doing this now. You can take a look when I will finish today and do a pull request.
Chris Sanders Front-End Engineer Sent from my iPhone
On Dec 14, 2014, at 8:07 AM, Ken Wheeler [email protected] wrote:
@astericky lets see what youre working with
— Reply to this email directly or view it on GitHub.
I made a pull request. I implemted this feature as a url param.
I did a little fiddle to demo setting individual carousels with querystrings. No additional code/change to html or slider js.
http://jsfiddle.net/x6uo6c32/
I still vote this not be a core feature, seems like additional code unecessary for most users, and probably frustrating for devs who want it to work "their way" :smile: