문제

I have this code in my route.

get '/custom_page/:name' => 'custom_page#load_content'

and in my controller is there any way i could get the value of this :name. Pls help. If my question is dumb please be sorry. I not so experienced in Rails

도움이 되었습니까?

해결책

You can access it by

params[:name]

I'm not very sure about this but it's worth giving a try

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top