I do apologize, I should explain my situation better. I'm working on a newspaper section, and I'm having a problem with the update_story_news.jsp file. The purpose of this file is to update a story that will appear on the newspaper's website.
What the page is supposed to do, is take the values from all the textboxes and areas, and forward them to the database. On previous projects, we have found that copying/pasting from Microsoft
Word would cause some problems when sending to the database. To rectify this, I coded a function that would replace certain problematic characters from word with an HTML equivalent character. For example Double Quotes "" and Single Quotes ''.
This project was originally started with 2 pages. The update page, and the confirmation page which sent back a message to the user letting them know if the update was successfully sent to the database or not. So what I had to do is find a way to incorporate my function in the Update page. (Trying to put the function on the confirmation page only led to further problems.)
So here's what I had in mind. (And correct me if you think my logic is flawed.)
On my update page, (when it loads), I would check a "UPDATE_TYPE" variable to see if this page is loading for the first time (which would mean that the user is updating a story). If this is the case, then the page is to load all the information from the database and display it on the form so the user can make modifications. When the user is finished making the changes and they click on "Submit", The UPDATE_TYPE variable changes to "INSERT" and the Update Page reloads itself. (So I'm calling the same page again)
Except this time when the page loads, I check to see if UPDATE_TYPE is equal to "INSERT". If it is, then I grab all the information from the URL using request.getParameter(), I run my functions to replace any special characters from the copy/paste from Word. And I need to forward all that information (that has just been changed) to the confirmation_news.jsp page. (Which uploads it to the database).
So here's where I'm having a problem. Anytime I try to forward the page I encounter errors. I've tried using
<jsp:forward page="(insert page here)"/></jsp:forward> But for some reason
it refuses to work, and
Tomcat kicks out a "Cannot Decode request URL" error. I'm not really sure what this means as I've never seen it before.
But any help you could lend me would be appreciated.
Thanks very much for your speedy responses
Medwyn