• Is there any way without altering the core code to stop the position being automatically reset.

    Right now I am using data-swpparentel to control where the search results are added – in this case a bootstrap grid, but its an inline form and I want the data to stretch all the way across a dropdown.

    My solution was to do the aboce and override width with css but the auto position screws it up.

    I looked through the JS and see that there is no way that I know of to disable the behavior, so while I do not like altering core code I added the following to the position_results: function ()

    
    // don't try to position a results element when data option set to false
    if ($input.data('swpposition') == false) {
    return;
    }
    

    Adding another data call to the input. This works perfectly but I wanted to know if there is a better way or if not could this be an option in the future.

    Regards,
    Jared

    • This topic was modified 7 years, 7 months ago by kiwiot.
  • The topic ‘Stop Automatic repositioning of results’ is closed to new replies.