URL REWRITING

What is meant by urlrewriting?

at waht purpose ae are using.

could you give me simple example
LVL 9
Manikandan ThiagarajanSenior consultantAsked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

TimYatesCommented:
http://httpd.apache.org/docs/2.0/misc/rewriteguide.html

basically you can specify rules so (for example)

    http://yourserver.com/some_old_page.htm

becomes

    http://yourserver.com/some_old_page.html

(ie html to html)

or you can point it to a new folder if the old one gets removed for example

its so that (hopefully) people will use the new URL rather than the old one slowly over time...

Tim
0
TimYatesCommented:
>> (ie html to html)

should read:

(ie htm to html)
0
Manikandan ThiagarajanSenior consultantAuthor Commented:
what purpose in session tracking?
0
Cloud Class® Course: CompTIA Cloud+

The CompTIA Cloud+ Basic training course will teach you about cloud concepts and models, data storage, networking, and network infrastructure.

rrzCommented:
Play with the following JSP.  You should be able to increment count with or without cookies.    

<%
  String url = request.getRequestURL().toString();
  String encoded = response.encodeURL(url);
  Integer count = (Integer)session.getAttribute("count");
  if(count==null)count = new Integer(0);
  session.setAttribute("count",new Integer(count.intValue() + 1));
%>
sessionId=<%=session.getId()%><br/>
isNew=<%=session.isNew()%><br/>
fromURL=<%=request.isRequestedSessionIdFromURL()%><br/>
fromCookie=<%=request.isRequestedSessionIdFromCookie()%><br/>
url=<%=url%><br/>
encoded=<%=encoded%><br/>
<a href="<%=url%>">Not encoded request</a><br/>
<a href="<%=encoded%>">Encoded request</a><br/>
count=<%=count%>  
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
TimYatesCommented:
>>  what purpose in session tracking?

Oh, right...  that means that if people don't have cookies turned on, it puts ;jsessionid=XXXXXXXXXXXX into the URL so that Tomcat knows what your session id is (normally it would come from a cookie)

Tim
0
rrzCommented:
Cut and paste the JSP I posted above here.  Watch the count !  Click on links.  Then turn off cookies in your brower ( use Firefox it is easier to avoid cookies ) and watch count.  
Is English  a second language for you ?    
0
Manikandan ThiagarajanSenior consultantAuthor Commented:
>>turn off cookies in your brower

how could i do that one.
0
TimYatesCommented:
Open the properties window

it should be in there.  Usually under a "privacy" header or something
0
rrzCommented:
I could never get IE browser to refuse my session cookie. Maybe due to the fact that I have it on Trusted site list. I tried locally and remotely but IE would not refuse for me.   I used  Firefox  and I was able to turn off cookies.  
stmani do you have Firefox ?  
0
rrzCommented:
>Maybe due to the fact that I have it on Trusted site list.  
I meant to say that I have my remote server on my trusted list.
0
Manikandan ThiagarajanSenior consultantAuthor Commented:
>>stmani do you have Firefox

yes i have mozilla fire box
0
TimYatesCommented:
Preferences ->  Privacy ->  Cookies ->  Allow sites to set cookies

(turn this off)
0
Manikandan ThiagarajanSenior consultantAuthor Commented:
where  i see the option preference ?

please tell me
0
TimYatesCommented:
Edit - Preferences

(or Tools -> Preferences under Windows I believe)
0
Manikandan ThiagarajanSenior consultantAuthor Commented:
i check that in browser.

that options were not there.

<<(or Tools -> Preferences under Windows I believe)


how could i check in windows.
0
TimYatesCommented:
what?
0
Manikandan ThiagarajanSenior consultantAuthor Commented:
>>Preferences ->  Privacy ->  Cookies ->  Allow sites to set cookies

where could i see prefrence option in mozillafirebox browser
0
TimYatesCommented:
Either under the "EDIT" or the "TOOLS" menu, depending on your OS  (as I said here: http:Q_21795134.html#16443838)
0
Manikandan ThiagarajanSenior consultantAuthor Commented:
i could not able to find  preference option in edit or tool option in mozilla firebox browser
0
TimYatesCommented:
What menu options do you have under "Edit" and "Tools" then?
0
rrzCommented:
Have you been able to turn off cookies in either browser ?  
0
Manikandan ThiagarajanSenior consultantAuthor Commented:
tools--websearch-readmail--newmessage--downloads---extension---themes---javascriptconsole

--pageinfo----clear private data--- options


edit--cut--copy--paste--undo---redo---delete---paste--selectall---findinthispage--find again


>>Have you been able to turn off cookies in either browser ?  

no
0
TimYatesCommented:
how about "Options"?

Tools -> Options
0
rrzCommented:
If you are still having problems then ask us here. Tell us step by step what you are doing and where you are having a problem.        rrz
0
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
JSP

From novice to tech pro — start learning today.

Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.