Still celebrating National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x
?
Solved

HTML Counter

Posted on 1998-10-12
3
Medium Priority
?
247 Views
Last Modified: 2010-04-09
I want to know what the code for constructing a page counter is.  I think it might be either in vbscript or asp(and maybe not).  It is for a course project and I have to write the code myself from scratch.  Thank you.
0
Comment
Question by:kristinca
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
3 Comments
 
LVL 75

Expert Comment

by:Michel Plungjan
ID: 1838646
So in order not to deprive you of the learning process, I will give you some hints:

1. The counter program must be server based since you need somewhere to store a file with the number that gets incremented.
2. The program reads this file (creates it and sets the value to 0 if the file does not exist), increments the value and writes the value back to the file and
3 returns some text (SSI or ASP) or an image (gif) or a redirect to an image representing the value of the counter.

Michel
0
 

Expert Comment

by:tunct
ID: 1838647
Have a look at www.TheCounter.com. This one offers lots of statistics & requires you to put some javascript into your page... might not be exactly what you want :)

The old way is to have an image tag with "src" parameter being a cgi-binary (there are also plain text counters). This means contacting your sysadmin and asking questions. You might try to link some off-site counters as well... just examine the html code of pages  which have counters.

Best Regards,
T.
0
 
LVL 10

Accepted Solution

by:
MasseyM earned 200 total points
ID: 1838648
I will give you the code, Here it is in ASP:

<%   ' Lock the Application object  
     Application.Lock  
     ' Increment the count
     Application("Count") = Application("Count") + 1
     ' Unlock the Application object
     Application.Unlock
%>

This is from the Microsoft MIND magazine...
0

Featured Post

Concerto Cloud for Software Providers & ISVs

Can Concerto Cloud Services help you focus on evolving your application offerings, while delivering the best cloud experience to your customers? From DevOps to revenue models and customer support, the answer is yes!

Learn how Concerto can help you.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This article describes how to create custom column layout styles for Bootstrap. The article uses 5 columns to illustrate the concept, but the principle can be extended to any number of columns.
This article demonstrates how to create a simple responsive confirmation dialog with Ok and Cancel buttons using HTML, CSS, jQuery and Promises
In this Micro Tutorial viewers will learn how to create navigation buttons that change on rollover, using CSS (Continuation of the CSS Image Sprite tutorial) Create a parent ID for all the list items       - Specify position: absolute and display: blockā€¦
Learn how to create flexible layouts using relative units in CSS.  New relative units added in CSS3 include vw(viewports width), vh(viewports height), vmin(minimum of viewports height and width), and vmax (maximum of viewports height and width).

660 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question