User Name Password Register
DaniWeb IT Discussion Community
All
What is DaniWeb IT Discussion Community?
You're currently browsing the JSP section within the Web Development category of DaniWeb, a massive community of 427,095 software developers, web developers, Internet marketers, and tech gurus who are all enthusiastic about making contacts, networking, and learning from each other. In fact, there are 2,299 IT professionals currently interacting right now! Registration is free, only takes a minute and lets you enjoy all of the interactive features of the site.
Please support our JSP advertiser: Lunarpages JSP Web Hosting
Views: 4293 | Replies: 1
Reply
Join Date: Mar 2006
Posts: 1
Reputation: aliz is an unknown quantity at this point 
Rep Power: 0
Solved Threads: 0
aliz aliz is offline Offline
Newbie Poster

Help Help!!!Need JSP Hit Counter

  #1  
Mar 1st, 2006
Hi every1,
Can you help me, Im trying to make a hit counter with JSP, But i want to read/write it to a file, so I dont loose the variable, can you please show mw the code to that, if you know.
Thank you
AddThis Social Bookmark Button
Reply With Quote  
Join Date: Feb 2006
Posts: 1,460
Reputation: masijade is just really nice masijade is just really nice masijade is just really nice masijade is just really nice masijade is just really nice 
Rep Power: 9
Solved Threads: 131
masijade's Avatar
masijade masijade is offline Offline
Nearly a Posting Virtuoso

Re: Help!!!Need JSP Hit Counter

  #2  
Mar 3rd, 2006
A hit counter is many times best done with a filter. Go to java.sun.com and
look at the j2ee tutorial. It is long and you will have to search for the counter
examples, but they are there. And remember, that even if the filter example
is shown for a servlet, it will also work for a jsp, as a jsp is really nothing other
than a servlet that is compiled by the app server rather than being precompiled.
Java Programmer and Sun Systems Administrator

----------------------------------------------

Debugging is twice as hard as writing the code in the first place. Therefore, if you write the code as cleverly as possible, you are, by definition, not smart enough to debug it.
--Brian Kernighan
Reply With Quote  
Reply

Only community members can participate in forum threads. You must register or log in to contribute.

DaniWeb JSP Marketplace
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)

 

Thread Tools Display Modes

Similar Threads
Other Threads in the JSP Forum

All times are GMT -4. The time now is 5:22 pm.
Forum system based on vBulletin Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
©2003 - 2008 DaniWeb® LLC