473,385 Members | 1,606 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,385 software developers and data experts.

Validate text box value whose name is an array

1
my html code is this:
Expand|Select|Wrap|Line Numbers
  1.                             <input type="text" name="curname[]" id="exRate" value="<?php echo($currency[$i]['rate']);  ?>" onClick="upActive()"> 
  2.  
textbox name is given as array.
how can i validate all values using javascript.
Oct 29 '07 #1
2 1886
numberwhun
3,509 Expert Mod 2GB
my html code is this:
Expand|Select|Wrap|Line Numbers
  1.                             <input type="text" name="curname[]" id="exRate" value="<?php echo($currency[$i]['rate']);  ?>" onClick="upActive()"> 
  2.  
textbox name is given as array.
how can i validate all values using javascript.
This is a javascript question and I am moving it to that forum. When asking your questions, please be sure to post them into the forum that is relevant to their topic.

Regards,

Moderator
Oct 29 '07 #2
acoder
16,027 Expert Mod 8TB
Welcome to TSDN!

I have changed the thread title to better describe the problem.
my html code is this:
Expand|Select|Wrap|Line Numbers
  1. <input type="text" name="curname[]" id="exRate" value="<?php echo($currency[$i]['rate']);  ?>" onClick="upActive()"> 
  2.  
textbox name is given as array.
how can i validate all values using javascript.
Since the text box has an id, just use document.getElementById("exRate") to access it. If you want, you can also access it using document.getElementsByName("curname[]")[0].
Oct 29 '07 #3

Sign in to post your reply or Sign up for a free account.

Similar topics

2
by: Meredith | last post by:
I am using a script to validate a form using the presence of a value in one field and determine if there is a value in one of two fields. It is an either/or situation. If the date rcvd field is...
1
by: aevans1108 | last post by:
Greetings All If this is the wrong place to post this question, please give me a push in the right direction. Thanks. I know there has to be a simpler way to do this, but this is as simple a...
11
by: TokyoJ | last post by:
I run a small camp in Alaska for kids and my director is asking for a web form. Could someone please have a look and offer some advice on where I'm making mistake(s)? I'm using the RegExp function...
1
by: anilareddy | last post by:
I have an application like this. I need to validate the start time in 2nd row against the start row in first row. I mean The start time value entered in the second row must not b the value entered in...
1
by: SkipNRun | last post by:
I am a novice when comes to JavaScript, AJAX. I am working on a form, which will allow users to update their contact information. In order to make the form flexible, I need to use pull down list. ...
1
by: mbarnhizer | last post by:
Hello All, Trying to figure out how to validate a series of questions on an online test. I am thinking that VB or Javascript is the best route, but your input may make a difference. The site i...
6
by: dream2rule | last post by:
Hello All, I am trying to validate multiple checkboxes whose values are stored in an array using php. I have been trying from a really long time but nothing's working out. Can anyone help? ...
18
vikas251074
by: vikas251074 | last post by:
I am using ASP In my company, all employees have to sent materials out of premises. Any employee who need to sent material out will use this web application. In the first page, an employee enters...
1
by: ghjk | last post by:
I'm having php page with validation. This is the code. <script language="javascript" src="../javascripts/validate.js"></script> <script type="text/javascript"> function valForm(){...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.