Hi,
How do I pass an array in a URL? such that at the other end rails will see it as an Array?
I’m trying to use the following bit of ActiveScaffold code:
params.reject {|key, value| [:controller, :action, :id].include?(key.to_sym)}.each do |key, value| next unless active_scaffold_config.model.column_names.include?(key) if value.is_a?(Array) <=== WHEN I TRY TO CREATE A URL WITH AN ARRAY AS A PARAMETER VALUE IT ALWAYS COMES OUT AS A STRING???
conditions = merge_conditions(conditions, ["#{active_scaffold_config.model.table_name}.#{key.to_s} in (?)", value])
else
conditions = merge_conditions(conditions, ["#{active_scaffold_config.model.table_name}.#{key.to_s} = ?", value])
end
end
thanks in advance