![]() |
javascript calling asp function
How can I call asp function from javascript?
|
Re: javascript calling asp function
Sehboo wrote:
> How can I call asp function from javascript? "javascript"? I assume you mean "client-side code", which can be written in other script languages besides javascript, depending on browser support ... Since this is a client-side question, it's offtopic for this newsgroup. You should post any followup questions to an appropriate group such as ..scripting.jscript. Anyways, the answer is: By requesting the page containing the function from the server. There are several techniques via which this can be accomplished: img elements, iframes, remote scripting, xmlhttprequest. The technique you use depends on whether you need to receive a value back from the server-side function. Bob Barrows -- Microsoft MVP -- ASP/ASP.NET Please reply to the newsgroup. The email account listed in my From header is my spam trap, so I don't check it very often. You will get a quicker response by posting to the newsgroup. |
Re: javascript calling asp function
Don't know if this might give you any ideas.
JavaScript function with an ASP variable. Response.Write "<script type='text/javascript'>alert('" & strMyASPVariable & "');</script>" JavaScript function with hardcoded text: Response.Write "<script type='text/javascript'>alert('Yet to be developed.');</script>" Best regards, J. Paul Schmidt, Freelance Web and Database Developer http://www.Bullschmidt.com Access Database Sample, Web Database Sample, ASP Design Tips *** Sent via Developersdex http://www.developersdex.com *** |
| All times are GMT. The time now is 09:29 AM. |
Powered by vBulletin®. Copyright ©2000 - 2013, vBulletin Solutions, Inc.
SEO by vBSEO ©2010, Crawlability, Inc.