[Okta Webinar] Learn how to a build a cloud-first strategyRegister Now

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 398
  • Last Modified:

How use tilda in respone.redirect

Is it possible to add https:// to response.redirect("~/order form.aspx") I use the same codebehind for several web sites and I use response.redirect("~/order form.aspx")  so the code can be easly used between different sites. Problem is some sites are secure. so i want to add https:// to the response.redirect("~/order form.aspx") . ANy ideas how I can do this?
0
whiwex
Asked:
whiwex
1 Solution
 
SriVaddadiCommented:
var url = String.Format("https://{0}{1}",  
      Request.ServerVariables["HTTP_HOST"] ,
      ResolveUrl("~/order form.aspx"));
 
      Response.Redirect(url);
0
 
whiwexAuthor Commented:
Thanks That worked great
0

Featured Post

VIDEO: THE CONCERTO CLOUD FOR HEALTHCARE

Modern healthcare requires a modern cloud. View this brief video to understand how the Concerto Cloud for Healthcare can help your organization.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now