There are two separators commonly accepted, and they are & and ;, while & is mostly used, I do rather use ; so, here's the patch to allow it to be changed.
Index: actionpack/lib/action_controller/url_rewriter.rb
===================================================================
--- actionpack/lib/action_controller/url_rewriter.rb (révision 4021)
+++ actionpack/lib/action_controller/url_rewriter.rb (copie de travail)
@@ -3,6 +3,7 @@
class UrlRewriter #:nodoc:
RESERVED_OPTIONS = [:anchor, :params, :only_path, :host, :protocol, :trailing_slash, :skip_relative_url_root]
+ PARAMETER_SEPARATOR = "&"
def initialize(request, parameters)
@request, @parameters = request, parameters
end
@@ -67,7 +68,7 @@
value.each { |val| elements << "#{key}=#{Routing.extract_parameter_value(val)}" }
end
- query_string << ("?" + elements.join("&")) unless elements.empty?
+ query_string << ("?" + elements.join(PARAMETER_SEPARATOR)) unless elements.empty?
query_string
end
end