Added wildcard pattern with block parameters in Spanish readme
This commit is contained in:
parent
1f2698454c
commit
188f99466d
|
@ -82,6 +82,12 @@ accesibles a través del arreglo <tt>params[:splat]</tt>:
|
||||||
params[:splat] # => ["path/al/archivo", "xml"]
|
params[:splat] # => ["path/al/archivo", "xml"]
|
||||||
end
|
end
|
||||||
|
|
||||||
|
O, con parámetros de bloque:
|
||||||
|
|
||||||
|
get '/descargar/*.*' do |path, ext|
|
||||||
|
[path, ext] # => ["path/al/archivo", "xml"]
|
||||||
|
end
|
||||||
|
|
||||||
Rutas con Expresiones Regulares:
|
Rutas con Expresiones Regulares:
|
||||||
|
|
||||||
get %r{/hola/([\w]+)} do
|
get %r{/hola/([\w]+)} do
|
||||||
|
|
Loading…
Reference in New Issue