struggling with redering ajax request for nonrefresh. May be a problem with rails.  Looking at ading xhr header tag to ajax request to solve the issue