Yes, that's what I am expecting, just can't see where the problem is, and I did the same running like you did and it works, but doing from the browser I can't get the value of "insert" or from any of the parameters into the perl.
Did you try running it from the browser?