title: How do I get the URL to change to the correct/current page with jQuery Mobile and Reponse.Redirect?
body: <p>I have an Inbox Message page that contains a list of messages sent to a person by another user.  Clicking on this message will open up a thread of messages between these two people with the ability to reply to a message sent by the original sender (this page is MessageContent.aspx).  This goes to another page (called MessageReply.aspx) that allows the person replying to create a new message in a textarea control with a button to "Send Message" which adds that reply to the end of the list of messages in the previous thread and does a Response.Redirect to go back to that page.</p>
  
  <p>Overall I have everything working how I want to, but the only issue now is that the URL never changes when going from the MessageReply page back to the MessageDetail (one containing all the thread messages) page.</p>
  
  <p>For example, the MessageDetail URL is "http://mysite/MessageContent.aspx?ThreadId=24".
  Replying to a message goes to this URL: "http://mysite/MessageReply.aspx?message=26".
  When the message gets sent to the Detail page and redirects to it, the URL still shows "http://mysite/MessageReply.aspx?message=26"</p>
  
  <p>Here is the code I have in the MessageDetail to open the Reply page (using a HyperLink control):</p>
  
  <pre><code>string url = SPContext.Current.Site.ServerRelativeUrl + "/MessageReply.aspx";
                  HyperLink ReplyHyperLink = (HyperLink)e.Item.FindControl("MessageReply");
                  ReplyHyperLink.Attributes.Add("rel", "external");
                  ReplyHyperLink.NavigateUrl = QueryStringUtils.AppendParameter(url, MessageQueryString, item.Id);
  </code></pre>
  
  <p>Here is the code I have for the MessageReply SendMesage button:</p>
  
  <pre><code>// Send the message
              var contentEditor = (HtmlTextArea)this.FindControl("ContentEditor");
              client.SendMessageReply(_messageId.Value, SubjectTextBox.Text, contentEditor.InnerText);
  
              Message message = client.Read(_messageId.Value);
  
              // Redirect back to the MessageContent page
              string url = SPContext.Current.Site.ServerRelativeUrl + "/MessageContent.aspx";
              string pageUrl = QueryStringUtils.AppendParameter(url, ThreadIdQueryString, message.ThreadId);
              Response.Redirect(pageUrl);
  </code></pre>
  
  <p>Anyone have any idea how to get the URL to change when it sends the message reply?  Everything else is working fine.  I greatly appreciate it :)</p>