Skip to content

Instantly share code, notes, and snippets.

@RemiBa
Created December 19, 2012 15:15
Show Gist options
  • Save RemiBa/4337411 to your computer and use it in GitHub Desktop.
Save RemiBa/4337411 to your computer and use it in GitHub Desktop.
Updating my filter selects not working... why is that?
$(document).ready(function(){
selectionChanges();
});
function selectionChanges(){
$('#filters select').change(function(){
//Do some stuff and do an ajax request
});
}
def show
#Do some things here
@properties
@newproperties
#Respond with the right format
respond_to do |format|
format.html
format.js
end
end
$('#filters').html('<%= escape_javascript(render :partial => "filterselect2") %>');
selectionChanges();
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment