output javascript to appear at end of page?

  • Thread starter Thread starter Tariq Ahmad
  • Start date Start date
T

Tariq Ahmad

hi,

i want to write some javascript at the *end* of my
rendered html page via my webform.

currently i am using response.write and it always
puts it at the top of my page.

using RegisterClientScriptBlock seems to put it
just after the VIEWSTATE bit at the top.

any help appreciated.

thanks.

t.
 
Here's an article that I wrote that explains the placement and use of
codebehind for emitting client-side script:

http://www.fawcette.com/vsm/2002_07/magazine/columns/aspnet/default_pf.asp

http://www.fawcette.com/vsm/2002_07/magazine/columns/aspnet/table1.asp

Ken

hi,

i want to write some javascript at the *end* of my
rendered html page via my webform.

currently i am using response.write and it always
puts it at the top of my page.

using RegisterClientScriptBlock seems to put it
just after the VIEWSTATE bit at the top.

any help appreciated.

thanks.

t.
 
BTW, you should not be using Response.Write for anything. It is deoprecated,
procedural in nature, and exists merely for backwards-compatibility for the
most part, unless you're writing a custom HttpHandler.

--
HTH,

Kevin Spencer
..Net Developer
Microsoft MVP
http://www.takempis.com
Big things are made up
of lots of little things
 
Back
Top