render和redirect的区别在于:
render 没有执行相对应的controller方法!而redirect_to 则重新执行controller方法,也就是说redirect_to 让浏览器去创建一个新的请求。
render 其参数是有效的,而redirect_to 其参数是重新请求的。
render 没有执行相对应的controller方法!而redirect_to 则重新执行controller方法,也就是说redirect_to 让浏览器去创建一个新的请求。
render 其参数是有效的,而redirect_to 其参数是重新请求的。