java script problem in struts ....

Hello Sir

I am getting a strange problem in my struts application. The problem is coming in IE but its working fine in Mozilla. The problem is as follows :

"

I have two url (given below) but the action (StoneAction in my case) and form-action(StoneForm) behind them is same and both of these urls lead us to two separate jsp pages (one for admin and other for search).

1) http://localhost:8080/InnovativeStone/research/showStones.do?dispatch=getStones

2)

http://localhost:8080/InnovativeStone/admin/showStones.do?dispatch=getStones

Now the problem is , i have a script function , in which i am calling the value of an input field like

"document.StoneForm.inputField.value" = true;

This is working fine in Mozilla but its giving problem in IE.

In IE its giving me "document.StoneForm.inputField.value" is null or not an object.

I am not finding any sloution. Please help me , i need it urgently. "

Thanx in advance

Khushwinder

[1020 byte] By [chahalkhushwindera] at [2007-11-27 10:20:03]
# 1

hi,

submit that jsp code file,

or try this,

<html:form action=".." type="...Action" name="StoneForm" >

--

--

</html:form>

in that form tag i mention beanname,

Am not sure, so please submit your jsp file, after we go for exact solution

drvijayy2k2a at 2007-7-28 17:01:22 > top of Java-index,Enterprise & Remote Computing,Web Tier APIs...
# 2

thanx for ur reply sir

but i have done that already but no success.

I have also noted one thing

that when i receive that hidden field like request.getParameter("hidden") its value is coming as null in one case but true in other case.

This is the problem .

As its coming from the same action i wonder why its value is coming as null...?

Is there problem with form intialization or something else...

plz give me some views

thanx a lot

chahalkhushwindera at 2007-7-28 17:01:22 > top of Java-index,Enterprise & Remote Computing,Web Tier APIs...
# 3

How is inputField defined in your jsp?

PatrickWanga at 2007-7-28 17:01:22 > top of Java-index,Enterprise & Remote Computing,Web Tier APIs...
# 4

Try this

document.getElementById("inputField").value

talk2keya at 2007-7-28 17:01:22 > top of Java-index,Enterprise & Remote Computing,Web Tier APIs...
# 5

If you are using html:text tag, you will need "styleId" attribute. Otherwise IE won't recognize the field.

PatrickWanga at 2007-7-28 17:01:22 > top of Java-index,Enterprise & Remote Computing,Web Tier APIs...