Skip to content

Instantly share code, notes, and snippets.

@salamoun
Created November 24, 2015 09:27
Show Gist options
  • Save salamoun/1c3ea786ba5bc3e94374 to your computer and use it in GitHub Desktop.
Save salamoun/1c3ea786ba5bc3e94374 to your computer and use it in GitHub Desktop.
XYZMO SESSION REDIRETOR
string userAgent = context.Request.UserAgent.ToLower();
log.Debug("userAgent: " + userAgent);
if (userAgent.Contains("ipad"))
{
String folderName = "&FolderName=CEZ";
bool removeFolderAfterFinish = true;
String iPadUrl = "significant://http.beta2.testlab.xyzmo.com:57003/WorkstepController.Process.asmx?WorkstepId=";
iPadUrl += workstepId + folderName + "&RemoveFolderAfterFinish=" + removeFolderAfterFinish + "&FolderName=" + "DMS";
context.Response.Redirect(iPadUrl);
}
else if (userAgent.Contains("android"))
{
String launchUrl = "http://launch.xyzmo.com/SignificantAndroidAppLauncher.aspx?WorkstepId=" + workstepId + "&server=beta2.testlab.xyzmo.com&port=57003&protocol=http";
context.Response.Redirect(launchUrl);
}
else if (1>0)
{
String launchUrl = "http://wsi/Sign.aspx?WorkstepId=" + workstepId;
context.Response.Redirect(launchUrl);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment