In a large saucepan on medium heat, melt butter and saute onions and jalapenos until tender, about 5 minutes. Add flour and stir to coat evenly, being sure to not burn the onions. Cook flour until golden brown, about 3 minutes. Whisk in milk and cheese and stir until melted, then remove from heat. Add the eggs to a small bowl, and stir in 1/4 cup of hot mixture to temper the eggs. Stir add the egg mixture into the pan, along with corn, and season with salt and pepper, to taste. Pour into a buttered 8 by 8-inch casserole dish. In a small bowl, mix together bread crumbs and Parmesan cheese. Sprinkle evenly over top of casserole, place in the oven and bake until custard sets and the top is golden brown, about 45 minutes.