Rui Ferns

Greenhorn
+ Follow
since May 06, 2001
Merit badge: grant badges
For More
Cows and Likes
Cows
Total received
In last 30 days
0
Forums and Threads

Recent posts by Rui Ferns

Hi all,
ok, ive just created a e-commerce web site using jsp.
This was a project I had to do for my final year in college.
I have to put up all the source code on the web so my lecturers can see it.
I want to store my code in HTML file, and I also want thes HTML files to highlight the syntax in different colors, to make it look clear instead of having it in black and white.
Is there any program out there that will let me convert my jsp files into HTML docs to show the code in the HTML doc and highlighted?
Need this to get me more marks for presentation.
All help is welcome.
Thanks
rui
23 years ago
Hi,
Does anyone know a quick,easy way to install SSL onto TOMCAT or if they know a web site that explains it clearly and well.
Somebody told me I might have to integrate Tomcat with Apache web server and then put SSL on. Is this true?
Any help on the topic is welcomed.
thanks
Rui
23 years ago
Hi all,
still having problems with this one.
Can anyone show me a simply WORKING example of JSP code telling the IE5 browser not to use cached pages and to reload the page if the user presses the back button.
Ive tried everything and no success.
Help would be very welcome.
Thanks
Rui
23 years ago
Hi,
I tried that and it still isn't working.
I must be doing something wrong.
Where exactly should I put the code you gave?
Should it be in the page I want not to be cached?
So when the user presses the back button this page doesn't appear?
thanks
Rui

Originally posted by Mark Simms:
<%
response.addHeader("Pragma", "NoCache");
response.addHeader("Cache-Control", "no-cache");
response.addDateHeader("Expires", 1);
%>
The official way is above......
be sure to warn users of the warning message they will get from their browsers....


23 years ago
Hi all,
Sorry for sending in this question again but nothing I try is working. I've tried setting the response headers to control the cache and Ive tried setting the meta eqiv tags but I still have my problem.
When the user hits the back button the previous pages is still there, I'm assuming its coming from the cache.
I read IE5 has a few problems but I can't resolve them with the fixes. If anyone has ever resovled a problem similar to this could they let me know how they did it?
Thanks
Rui
23 years ago
Hi all,
My problem is,I want to know how to stop users from seeing previous pages by using the back button. Like if someone fills out form fields and then submits and leaves the PC and then another user comes along and hits the back button then they can see all the past users sensitive info in the form fields.
It seems the browser is retrieving the cached pages.How can I stop this from happening. I'd like to have it that if a person tried to hit the back button then they are taken to a warning page telling them that they can't view this page and give them a link to the start page.
I've tried various methods to solve this problem but none seem to work properly.
Could anyone tell me how to tell a jsp not to use the cached pages?
thanks
Rui
23 years ago
Hi all,
Can anyone tell me hoe to clear form fields after clicking on the submit button.
I have fields which contain sensitive info. When the submit button is clicked the data is sent to another JSP. But how can I clear these fields after submitting?
Thanks
Rui
23 years ago
Hi all,
I have to have a final year project in by the 24th and
im running out of time. I'm a beginner to JSP.
I want to create a shopping cart so users can add
products,remove products,view their cart and checkout.
I want to retrieve the products from the database and
store them on a web page with a link beside each one
to let the user add it to their cart.
I don't know where to start?
Is their an easy way to do this? Or a web site that
shows you how to go about doing this.?
When the users adds some products and checks out by
filling out the forms, this info along with the
products they bought should be put into a database
table.
Any ideas or help would be much appreciated.
thanks
rui
23 years ago
Hi all,
I want to write a few classes for my shopping cart.
I will have a Item.java,Billing.java,Shipping.java and a ShoppingCart.java.
I have a main DisplayShoppingCart.jsp file that will use those classes.
Can someone tell me how to create a package containing all my class files and where to put this package so the jsp file knows where to get them.
Also do I have to change my classpath?
I tried creating a subfolder in the folder which contains my jsp files and naing it cart. I placed all my class files in there and used the :
<%@ page import="cart.*"%> but It did'nt work.
What am i doing wrong?
Should I be putting my class files in the WEB-Inf/classes folder?
Any help would be appreciated.
Thanks Rui
23 years ago
Hi all,
Ok, I have a MS Acess database.(I'm using Access cause I'm doing a small project and i'm a beginner in Jsp)
In the database is a table with 4 columns. I want one column to contain links so when I retrieve data from the table and put them in a HTML table, users will be able to click the links. I also have a page whereby a user can edit a the database table. This works by retrieving the data from the table and putting it in form fields on a web page so the user can edit the fields and update the database.
The links in the database table are stored as :
<a href ="url">link</a>
When this is retrieved and put in a html table it is displayed as a link, but the problem occurs when I retrieve the data to be put in the form fields. I just want the <a href ="url">link</a> to be displayed,but only the <a href is displayed and part of the link is displayed outside the form.
Strange stuff.
Anyone know a solution.
Thanks Rui
23 years ago
Hi,
Thanks got it working.
That was a silly mistake.
I'm using index cause it is a value of 1 of 10 submit buttons.
Its lets me know which one I clicked on.
Thanks for the help.
Rui
23 years ago
Hi all,
I have a page where a user fills in a form field.
When they hit submit the page is sent to a database checker page where I want to retrieve all rows in the table containing the string the user entered in the form field. I'm not sure how to write this SELECT statement.
I get this error when I hit the submit button:
"javax.servlet.ServletException: [Microsoft][ODBC Microsoft Access 97 Driver] The SELECT statement includes a reserved word or an argument name that is misspelled or missing, or the punctuation is incorrect"
Heres the part of my code:
Basically I want to retrieve all the rows containing the string the user entered in the form field.
=================================================================
<%
if((request.getParameter("KenSearch")) != null)
{
String index = request.getParameter("KenwoodChoice");
PreparedStatement pstmt = conn.prepareStatement("SELECT FROM PRODUCTS WHERE DESC = (?)");
pstmt.clearParameters();
pstmt.setString(1, index);
ResultSet rs = pstmt.executeQuery();
}
=================================================================
Thanks
Rui
23 years ago
Hi,
Thanks for the help.
I got it working.
I'm not sure what the session time out is. I haven't set it yet.
What is the default session time out?
And how do you set it?
Thanks again
rui
23 years ago
Hi,
I have a login page that lets a user enter his/her username and password. If valid it takes them to a page where they can administer a table in their database using form fields.
My question is, if another user comes along after somebody has been logged in,and presses the back button or forward button on the browser and gets passed the login page to see the administraion page , how can I stop this.
Could anyone tell me how I can stop this from happening. I'd like to use sessions but i'm not sure on how to go about it.
Thanks
Rui
23 years ago
Hi,
Since your last mail, i've been trying loads of things and it works now. Your right in what you told me to change.
I wasn't using DriverManager and now I am in the two files.
Thats a relief off my shoulders.
Thanks for being so patient.
I appreciate the help.
If u ever need any help, let me know.
Thanks
rui
23 years ago