0

I have a modal window created and I am able to show the window perfectly. I have passed the title as parameter and was able to see in the modal window, but I cannot find the code behind for me to retrieve the value of the title. The value of this.Page.title is always "\r\n\t".

var options = {
  url: uploadUrl,
  title: documentType,
  autosize: true,
  allowMaximize: true,
  showClose: true
};

1 Answer 1

1

Easiest way to get title in code behind is to attach it as query-string to URL and retrive that query-string in code-behind

var options = {
url: uploadUrl+"?title="+mytitle,
title: documentType,
autosize: true,
allowMaximize: true,
showClose: true
};

in .CS

  string title = Request.QueryString["title"];
1
  • Hi, I am trying to avoid this approach as I am trying to optimize my code. By theory, the title should be retrievable somehow. I am looking for an answer that may involves retrieving the info via jquery and assign it to a code-behind variable but I could not formulate how to reach this goal.
    – Joe
    Commented Mar 17, 2015 at 11:55

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.