• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Visitor Counter for website

 
Ranch Hand
Posts: 282
Eclipse IDE Firefox Browser Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I have a company website that I want to add a visitor counter to. Its an internal website so I cant add a counter that would call anything outside of the internal website eg. sitemeter... I have tried php scripts that I found online and one java script that I found online and they seem to not do anyhting. I assume its my setup that is causing the problem. I have IIS installed(was already installed before I got here, by the last guy). This site has some jave script and PHP that actually does work. I am just trying to add a counter to the main page. it called default.htm right now. the code I was using just opens a file, reads the number, adds 1 to it,displays it on the screen and then closes it back. pretty simple except that it doesn't work.
 
Sheriff
Posts: 67746
173
Mac Mac OS X IntelliJ IDE jQuery TypeScript Java iOS
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
JavaScript can't do any file access. What is? The php?

I'm not sure what you are expecting without showing the code that "doesn't work".
 
James Hambrick
Ranch Hand
Posts: 282
Eclipse IDE Firefox Browser Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I am looking for code that will work, code that will create a visitor counter.
[ August 02, 2007: Message edited by: James Hambrick ]
 
Bear Bibeault
Sheriff
Posts: 67746
173
Mac Mac OS X IntelliJ IDE jQuery TypeScript Java iOS
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
What will you be using for the server-side code?
 
James Hambrick
Ranch Hand
Posts: 282
Eclipse IDE Firefox Browser Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
on the server I have renamed the .htm file to .php4 and it runs. Seems that PHP ignored any code inside a .htm file. I have a php opening a file, adding one to the number, displaying it on the screen and then saceing and closing the file.


you can change the .htaccess file to tell php to check for php code inside of html files, but I dont have a .htaccess file and they said that it was setup by IIS. I could not find anywhere in IIS where it was setup. that's why I just renamed the file.
 
reply
    Bookmark Topic Watch Topic
  • New Topic