Question: I can't use friendly URLs in my DotNetNuke site and a module that I want to use requires it. The problem is when they post to the 2nd part of the module process they tack on a "?ctlname=Step2" and then "?ctlname=Step3" for the next step. So...

the Url ends up being something like this:

default.aspx?tab=123\**?*\*ctlname=Step2

I'm trying to solve this by rewriting the URL. This seems like it should work but doesn't.

```
<RewriterRule>
  <LookFor>.*/Default.aspx\?tabid=123(\?ctlname=.*)$</LookFor>
  <SendTo>~/Default.aspx?tabid=123&amp;ctlname=$1</SendTo>
</RewriterRule>

```

Any help would be appreciated!

Answer: 
When I use your code I get integer keys (rails 3.07), what's the column type of id?

If you want to do it manually:

```
new_hash = hash.inject({}){|h,a| h[a.first.to_i] = a.last; h}

```
```
new_hash = Hash[hash.map { |k, v| [k.to_i, v] }

```