Wrox Programmer Forums
|
ASP.NET 1.0 and 1.1 Basics ASP.NET discussion for users new to coding in ASP.NET 1.0 or 1.1. NOT for the older "classic" ASP 3 or the newer ASP.NET 2.0.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the ASP.NET 1.0 and 1.1 Basics section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old December 23rd, 2008, 06:42 AM
Registered User
 
Join Date: Dec 2008
Posts: 5
Thanks: 0
Thanked 0 Times in 0 Posts
Default about javascript

how to use a javascript file into a part of aspx file.
plz need example.
 
Old December 23rd, 2008, 12:37 PM
Imar's Avatar
Wrox Author
 
Join Date: Jun 2003
Posts: 17,089
Thanks: 80
Thanked 1,576 Times in 1,552 Posts
Default

Hi there,

I am not sure I understand what you're asking.... Are you looking for a way to reference a JavaScript file from an ASPX file? If so, you can use the standard syntax for that:

HTML Code:
<script src="/JavaScripts/SomeFile.js" type="text/javascript"></script>
Hope this helps,
Imar
__________________
Imar Spaanjaars
http://Imar.Spaanjaars.Com
Follow me on Twitter

Author of Beginning ASP.NET 4.5 : in C# and VB, Beginning ASP.NET Web Pages with WebMatrix
and Beginning ASP.NET 4 : in C# and VB.
Did this post help you? Click the button below this post to show your appreciation!

Last edited by Imar; December 23rd, 2008 at 12:41 PM..
 
Old December 23rd, 2008, 09:04 PM
Authorized User
 
Join Date: Dec 2008
Posts: 50
Thanks: 1
Thanked 5 Times in 5 Posts
Default

or you can use the following syntax in your <head> tag

use

<script type='text/javascript'>

alert('hello world');

</script>

thanks





Similar Threads
Thread Thread Starter Forum Replies Last Post
JavaScript. Magxtopher Javascript 2 April 1st, 2014 09:27 PM
stop current javascript function using javascript sakthi Javascript 3 June 2nd, 2008 03:30 PM
"text/javascript" and "javascript" rupen Javascript 1 June 24th, 2005 07:20 AM
new to javascript shankhan Javascript 2 April 26th, 2005 05:34 AM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.