Ask a Question related to ASP.NET General, Design and Development.
-
Tariq Ahmad #1
output javascript to appear at end of page?
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.
Tariq Ahmad Guest
-
How do you output the Euro symbol intext/HTML/Javascript?
Inserting the euro symbol causes problems. Some users report that they get a question mark, others that they get a little square. The problem... -
JavaScript entered in a page blocks editing page inContribute
I have entered a set of JavaScript tags into a html page via FTPand the page displays correctly on the web. When I go to Contribute to and attempt... -
Output a query into simple Javascript
Hi I have a query the results of which I'd like to use in Javascript to form the items in a dynamic menu.... eg i run query with results..... -
Getting page output
Is there a tag or method I can use to grab the page output so that I can amend it prior to outputting. -
output text in control location; calling control javascript from page javascript
Hi; If you don't know, I'm just learning javascript and aspnet, but I have a pretty good grounding in windows programming. I'm trying to build a... -
Karl Seguin #2
Re: output javascript to appear at end of page?
I believe Page.RegisterStartupScript does what you are looking for.
Karl
"Tariq Ahmad" <tariqnahmad@hotmail.com> wrote in message
news:O3ieeV6RDHA.3700@tk2msftngp13.phx.gbl...> 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.
>
>
Karl Seguin Guest
-
Ken Cox [Microsoft MVP] #3
Re: output javascript to appear at end of page?
Here's an article that I wrote that explains the placement and use of
codebehind for emitting client-side script:
[url]http://www.fawcette.com/vsm/2002_07/magazine/columns/aspnet/default_pf.asp[/url]
[url]http://www.fawcette.com/vsm/2002_07/magazine/columns/aspnet/table1.asp[/url]
Ken
"Tariq Ahmad" <tariqnahmad@hotmail.com> wrote in message
news:O3ieeV6RDHA.3700@tk2msftngp13.phx.gbl...
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.
Ken Cox [Microsoft MVP] Guest
-
Kevin Spencer #4
Re: output javascript to appear at end of page?
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
[url]http://www.takempis.com[/url]
Big things are made up
of lots of little things
"Tariq Ahmad" <tariqnahmad@hotmail.com> wrote in message
news:eiXK$86RDHA.1324@TK2MSFTNGP11.phx.gbl...[url]http://www.fawcette.com/vsm/2002_07/magazine/columns/aspnet/default_pf.asp[/url]>
> excellent articles - thanks!
>
> "Ken Cox [Microsoft MVP]" <BANSPAMken_cox@sympatico.ca> wrote in message
> news:eTIe2u6RDHA.1304@TK2MSFTNGP11.phx.gbl...> > Here's an article that I wrote that explains the placement and use of
> > codebehind for emitting client-side script:
> >
> >>> >
> > [url]http://www.fawcette.com/vsm/2002_07/magazine/columns/aspnet/table1.asp[/url]
> >
> > Ken
> >
> > "Tariq Ahmad" <tariqnahmad@hotmail.com> wrote in message
> > news:O3ieeV6RDHA.3700@tk2msftngp13.phx.gbl...
> > 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.
> >
> >
> >
>
Kevin Spencer Guest
-
Unregistered #5
output javascript to appear at end of page?
Use RegisterStartupScript it will work
Unregistered Guest



Reply With Quote

