I have a form on a non-SSL page that I want to submit as SSL. I am creating the form using Html.BeginForm but that isn’t required.
It would also be nice if I could make it configuratble, so that i could have a flag that I set so that on the dev server or on my laptop I can turn the SSL off and turn it on in the production server.
I know that I could just make the entire URL a config item but I was hoping that I could make it more flexible so I could just have a true or false setting.
You can override the action attribute of the form created by Html.BeginForm.
Note the use of the Model.UseSSL flag, which should be passed to this View by its Controller.