Created
September 30, 2013 08:48
-
-
Save thomasstr/6761020 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<script type="text/javascript"> | |
$(document).ready(function () { | |
$("#project_postnumber").blur(function(){ | |
$.ajax({url: '/project/postplace', type: 'POST'}) | |
.done(function(response){ | |
$("#project_postplace").val(response); | |
}); | |
}); | |
}); | |
</script> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def postplace | |
@find_postplace = Postnumberregister.find_by_postnumber(params[:postnumber]) | |
render :text => @find_postplace.postplace | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment