how to clone an old .jsp url?

lenglain

New Member
Hi, I work for a non-profit organization and they have me doing everything including all the website stuff.

today we got an email informing us that some research papers cite a paper we publiches in 2002 but the link is now obsolete, the paper is now at a new address on the new website.

Here is the link

www.ournonprofitsite.org/pov/position_item.jsp?pov_id=35

I was thinking to simply create a new "/pov/" folder and then create a "position_item.jsp?pov_id=35" file with a simple redirect script to the new page, but dreamweaver is telling me that I cannot put special characters like "?" "_" or "=" .

Any ideas on what I could do to make that old link work for anybody clicking on it?

Thank you.
 

chrishirst

Well-Known Member
Staff member
HTML:
<a href="http://www.ournonprofitsite.org/pov/position_item.jsp?pov_id=35">Click Here</a>
 

chrishirst

Well-Known Member
Staff member
Or meta redirect

HTML:
<meta http-equiv="refresh" content="0;url=http://www.ournonprofitsite.org/pov/position_item.jsp?pov_id=35">
 

lenglain

New Member
Ok thanks for your help, but the old page in question no longer exists, so there is no page to insert the redirect in, that's why I was confused by your answer. I would like to find a way to generate that old url again so that I can then insert a redirect to the new url (which I already knew how to do).

But what I don't know how to do is generating that url again, I can't just make a file with the same url since I cannot put special characters in a file.
 

chrishirst

Well-Known Member
Staff member
But what I don't know how to do is generating that url again, I can't just make a file with the same url since I cannot put special characters in a file.

That's only because you are using Dreamweaver.

Does the server no longer run JSP? (Apache TomCat)?
Have you access to a .htaccess file to rewrite or alias that one URI?
What server side scripting does the server run?
 

lenglain

New Member
Our organization's site is a wordpress installation running on Cpanel, the only thing I see in Cpanel is an Apache handler tool that lets me add handlers for apache to treat as various extensions. For now the only two handlers configured are cgi-script (to be handled as .cgi .pl .plx .ppl .perl) and server-parsed (.shtml.) That's all I've been able to gather.

Meanwhile I did try to create an html file from the cpanel back-end with the jsp address, but it changes the "?" and "=" to "%" so that the url is different than what I'm trying to recreate.

I don't see anything mentioning javascript in the Cpanel back-end, is it possible that it just doesn't come configured to serve .jsp pages?

Thanks for your help...my boss is pretty demanding he seems to think this is something that should have been easily been fixed within 5 minutes.
 

chrishirst

Well-Known Member
Staff member
.jsp is nothing at all to do with javascript. JSP is an acronym for Java Server Pages.


Create a folder /pov/ with a file called position_item.jsp and a file called .htaccess in it. Take careful note that .htaccess STARTS with a dot character

Add this line to that .htaccess
Code:
AddType text/html .jsp

and in "position_item.jsp" put
HTML:
<html>
<head>
<meta http-equiv="refresh" content="0;url=/OurReport/">
</head>
<body></body>
</html>

Is probably easier than working out a .htaccess redirect
 
Last edited:
Top