Ask a Question related to ASP.NET General, Design and Development.
-
nic #1
get ~/mypage.aspx for use in dynamic javascript
Hi,
I need to get the equivilent of Response.Redirect
(~/mypage.aspx) for a dynamic javascript function.
Essentially I am writing the javascript on the non-code
behind page and need to inject the "~" so I can have a
relative path to my page. So here is the javascript
function:
function showHelp(fieldID)
{
var ahref = "FieldHelp.aspx?FieldID=" + fieldID;
var win = window.open(ahref,"","height=200,width=400");
}
I need the ~/FieldHelp.aspx path but don't know how to get
it. I tried
var ahref = "<%= ~/FieldHelp.aspx%>?FieldID=" + fieldID;
but that doesn't work.
I think injecting serverside code in a dynamic javascript
funtion makes the function more readable than to build it
all server side and inject the whole stream.
Thanks
nic Guest
-
Writing javascript code in every page of my site using aspx
Good Morning, I would want to use aspx to write this javascript code for me in every page of my site www.etantonio.it how can I do this ??? ... -
Calling external javascript from .aspx file
I have an aspx file which calls javascript written in another file. The point is that I am trying to pass some parameters from this aspx page to... -
Aspx - how to add dynamic controls
All, How can add a control dynamically in a html table on an aspx page? here is the scenario User selects a dropdown for car make, then based... -
How to include javascript in aspx page
hi, I have javascripts for my Old ASP application i was using <script language="javascript" type="text/javascript"... -
Dynamic creation of web pages without .aspx files
I am experimenting with dynamically creating pages containing custom controls in response to http requests caught by an http handler, in place of...



Reply With Quote

