bjorn2404 / jQuery-Store-Locator-Plugin

A store locator plugin using Google Maps API version 3
MIT License
495 stars 235 forks source link

Search with pagination #79

Closed julienwa closed 8 years ago

julienwa commented 9 years ago

Hi,

When I am on page 2 and search again we stay on page 2 instead of coming back on page 1. Is it possible to come back page 1 when clicking on search button while on other page ?

Thanks

bjorn2404 commented 9 years ago

Hello,

Hmm.. yeah it should reset. I'll get that fixed in the next couple of days.

Thanks

bjorn2404 commented 8 years ago

Ok, I've pushed a fix to the dev branch but I've got a couple of other things I want to do before pushing to master. If you are looking for a fix in the meantime you can update the page check that starts on line 1629 to:

// Set the initial page to zero if not set
if ( _this.settings.pagination === true ) {
    if (typeof page === 'undefined' || originalOrigin !== addressInput ) {
        page = 0;
    }
}
bjorn2404 commented 8 years ago

Fixed in v2.2.0