Still celebrating National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x
?
Solved

Retrieving values of a text box

Posted on 2000-05-03
1
Medium Priority
?
766 Views
Last Modified: 2008-03-06
  I have an input box in a form with the name having a dot in it,;i.e; a name like "abc.txt". I want to get the value of this input box in a javascript function. How do I do it?
Thanx in advance,
Divya.
0
Comment
Question by:divya234
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
1 Comment
 
LVL 1

Accepted Solution

by:
clim1219 earned 225 total points
ID: 2775924
divya234,

at first i have a hard time how to find a solution for your problem but now i am proud to tell you that i got it.

just copy and past the code below.
i am using an IE browser i don't know if it works with netscape.



<HTML>
<HEAD>
<script>

function showValue()
{
sValue = document.all["abc.txt"].value ;
alert( sValue ) ;
}

</script>
</HEAD>
<BODY>

<P>Name: <INPUT name="abc.txt"></P>
<P><INPUT name="btnClick" type=button value="Click Me" onClick="showValue()"></P>

</BODY>
</HTML>
0

Featured Post

Enroll in September's Course of the Month

This month’s featured course covers 16 hours of training in installation, management, and deployment of VMware vSphere virtualization environments. It's free for Premium Members, Team Accounts, and Qualified Experts!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Having worked on larger scale sites, we found out that you are bound to look at more scalable solutions to integrating widgets, code snippets or complete applications and mesh them into functional sites, in any given composition. To share some of…
This article discusses how to implement server side field validation and display customized error messages to the client.
The viewer will learn the basics of jQuery, including how to invoke it on a web page. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery.: (CODE)
The viewer will learn the basics of jQuery including how to code hide show and toggles. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery…

670 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question