hello all
i’m using rails3.0.10
def districts
@names = Node.where("name like ?",
“%#{params[:term]}%”).limit(5).map(&:name)
respond_to do |format|
format.json {render :json => @names}
format.xml {render :xml => @names}
end
end
render xml get right names
but render json make the names is encoded
any help?
Thanks in advance