Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Validation Check On Text Field

Status
Not open for further replies.

jgd12345

Technical User
Apr 22, 2003
124
GB
Hey does anyone know what the problem is with
I had everything working fine earlier but then I added a validation check to see that the numbers are not the same for each text box on each line.

I'd be greatful if you could help because it's been troubling me all day. Thanks
 
A quick check of your source code showed me that you're doing comparisons between values using a single-equals sign (=) instead of the double-equals sign (==).

Change those first and report back if there's still a problem.

'hope that helps.

--Dave
 
Hi yeah my bad that fixed it. Thanks

I've run into another problem now say I've got an text box:

<input type="text" name="drawGameBoards[0].numbersChosen[0]" class="text">

If I pass this variable across using a php script then what would it be called. My instincts were that it would be $drawGameBoards[0].numbersChosen[0] but that returns a parse error.

I know this is hardly a javascript issue but i'd be greatful if anyone could help. Thanks
 
<input type="text" name="drawGameBoards[0].numbersChosen[0]" class="text">

That is not the way to dynamically insert a variable into an attribute of an HTML tag.

If I were doing a JSP, I might have something like:

<input type="text" name="<%=drawGameBoards[0].numbersChosen[0]%>" class="text">

...but that is not what you asked.

I recommend you start a new thread to ask this question. If it is not a JavaScript question, find the right forum for the question.

--Dave
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top