history.back problem with firefox

M

mohammed.naghman

Hi,

I have 2 submit buttons in a jsp page. One of them takes me to
page2.jsp and also passes the values enetered to page2.I have a link
in the page2 that does a history.back to come to the previous page to
make any chnages necessary. Now after making my changes, instead of
going to page2.jsp if I want to submit the page, Instead of submitting
the page it takes me to page2.jsp again.

This problem is only with firefox. It works fine with IE. Can anyone
help me on this?
 
M

mohammed.naghman

On Feb 23, 9:18 am, (e-mail address removed) wrote:
...


Have you validated the HTML?

Andrew T.



Yes I have. I hope u mean the validation of the fields in the html
page. Correct me if I am wrong.
 
A

Andrew Thompson

...
Yes I have. I hope u mean the validation of the fields in the html
page. Correct me if I am wrong.

No. I do *not* mean a validation (via JavaScript
or other means) of the *content* of the fields.

I mean, have you validated the HTML that is
produced by the JSP?

It is possible to validate HTML here..
<http://validator.w3.org/>

Note. If this is some 'local server' or
intranet that is not expeosed ot the
wider internet, you may need to save a
static version of the HTML to file before
it can be validated.

I suggest this, because Java programmers
have a habit of assuming 'any old rubbish'
they write is (valid) 'HTML', when it is
not valid HTML.

Andrew T.
 
M

mohammed.naghman

No. I do *not* mean a validation (via JavaScript
or other means) of the *content* of the fields.

I mean, have you validated the HTML that is
produced by the JSP?

It is possible to validate HTML here..
<http://validator.w3.org/>

Note. If this is some 'local server' or
intranet that is not expeosed ot the
wider internet, you may need to save a
static version of the HTML to file before
it can be validated.

I suggest this, because Java programmers
have a habit of assuming 'any old rubbish'
they write is (valid) 'HTML', when it is
not valid HTML.

Andrew T.

Oh yes, I have validates using the w3c validator. The page has no
errors.
 
M

mohammed.naghman

Oh yes, I have validates using the w3c validator. The page has no
errors.- Hide quoted text -

- Show quoted text -

And I have re-written my problem here:



I have Page1.jsp with 2 buttons. One button is used to navigate to
Page2.jsp and is a submit button. It submits the values enterd in
page1 to page2. This is done since some of the fields are common in
both pages and we do not want the user to re-enter the values if he
has already done so in page1.

The second button is again a submit button. But this one submits the
values of the fields entered in Page1.jsp and writes into the
database.

Now I use button1 and go to Page2.jsp, And I come back to page1.jsp
using a link that does a history.back(). I do this becoz I dont want
to enter anything in page2.jsp. So I come back to page1 and try to
submit the page using button2. Now instead of submitting the page and
writing to the databse, button2 behaves like button1 nad takes me to
page2.jsp again.

And this problem is only with firefox.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
474,262
Messages
2,571,050
Members
48,769
Latest member
Clifft

Latest Threads

Top