Mercurial > altnet-hispano
comparison Agendas/trunk/src/Agendas.Web/Controllers/AccountController.cs @ 92:7027cda13de3
Armado de la url de retorno en base a la url del request
author | Nelo@Kenia.neluz.int |
---|---|
date | Fri, 03 Jun 2011 23:58:03 -0300 |
parents | d1688622fa88 |
children | 65f0b3d70c18 |
comparison
equal
deleted
inserted
replaced
91:9dfbe4e29c6a | 92:7027cda13de3 |
---|---|
63 | 63 |
64 if (Request["oauth_token"] == null) | 64 if (Request["oauth_token"] == null) |
65 { | 65 { |
66 //Redirect the user to Twitter for authorization. | 66 //Redirect the user to Twitter for authorization. |
67 //Using oauth_callback for local testing. | 67 //Using oauth_callback for local testing. |
68 oAuth.CallBackUrl = "http://localhost:1424/Account/TwitterLogOn"; | 68 var action = Url.Action("TwitterLogOn"); |
69 var url = Request.Url.Scheme + "://" + Request.Url.Host + | |
70 (Request.Url.Port != 80 ? ":" + Request.Url.Port : string.Empty) + action; | |
71 | |
72 oAuth.CallBackUrl = url; | |
69 Response.Redirect(oAuth.AuthorizationLinkGet()); | 73 Response.Redirect(oAuth.AuthorizationLinkGet()); |
70 } | 74 } |
71 else | 75 else |
72 { | 76 { |
73 //Get the access token and secret. | 77 //Get the access token and secret. |