How to Create a Web Counter

by Faizah Imani

If you were asked the question how many visitors came to your home today, chances are great that you would have the answer. Having a home on the Internet is similar to having a home in the real world. You want to know who is coming in and out of your home. Plus, you want to know how many visitors you have on any given day. By adding a web counter to your website, you can keep track of those important statistics.

Ensure that your website editor is capable of handling PHP script. If you are uncertain, check with your web hosting company.

Log in to the Control Panel of your web hosting account. Open "File Directory."

Locate the "index.html" file that is in your file directory. Rename the file "index.php." Save the file with the new name.

Create a new file inside of your file directory named "counter.txt." Do not enter any text inside of the file. Save the file.

Open "index.php." Enter the appropriate PHP code for your counter (see link in References). Some knowledge of HTML coding is required to insert the PHP code. Save "index.php" once you have entered the PHP code.

If you would like to create a web counter for your website that does not contain PHP script, there are websites that are capable of that (see link in Resources). These websites will allow you to create a counter easily by asking a few simple questions. After you have answered the questions, you will be given HTML code for the free counter you created. Just copy and paste the HTML code onto the web page where you want the counter to appear.

About the Author

Faizah Imani, an educator, minister and published author, has worked with clients such as Harrison House Author, Thomas Weeks III, Candle Of Prayer Company and "Truth & Church Magazine." Her dossier includes JaZaMM WebDesigns, assistant high-school band director, district manager for the Clarion Ledger and event coordinator for the Vicksburg Convention Center.

Photo Credits

  • photo_camera Getty Images