counter on files?

ludlo

OSNN Addict
Joined
Dec 7, 2001
Messages
96
#1
hello

im running sambar server on a computer at home, and i need to check how many times a file has been downloaded, or start checking that.

how can i code this?

thanks
 

Zedric

NTFS Guru
Joined
Jan 12, 2002
Messages
4,006
#2
[Edit]Oh dear, i read Apache, not Samba. :D Well in Samba, I have nooo idea, not even sure it's possible. Especially since you don't really "download" through Samba.


** Old crap**

You could du it by using a small tracker and link to that instead of the file.

Like file.zip becomes dltracker.php?file=file.zip

The dltracker.php just increments the counter (in a file or database or whatever, your choice) and redirects to file.zip. This would however not work with direct links.

Another choice would be to parse through the Apache access logs to find the number of hits. This could get a bit messy though. ;)
 

ludlo

OSNN Addict
Joined
Dec 7, 2001
Messages
96
#5
well, dont know what samba is but im using SAMBAR web server :) but apache seems better, will download it and learn it. is it difficult to use apache?
 

Zedric

NTFS Guru
Joined
Jan 12, 2002
Messages
4,006
#6
ludlo said:
well, dont know what samba is but im using SAMBAR web server :) but apache seems better, will download it and learn it. is it difficult to use apache?
Oooohhh sambaR, *doh*, my mistake. :D Never heard of it.

Apache is definately good, it's the most widely used on the net (I think). It's not very hard to use, but I don't know how easy sambar is so. ;)


Samba btw is software you can use to share files between a Linux computer and a Windows computer for instance.
 

ludlo

OSNN Addict
Joined
Dec 7, 2001
Messages
96
#7
ahaa =) okej then i know what samba is :p

in sambar, you put your html files under sabar/docs/ and the you start it. not too much of setting up :p
 

Members online

No members online now.

Latest posts

Latest profile posts

Perris Calderon wrote on Electronic Punk's profile.
Hey ep!

All good with me, applying for microsoft mvp right now, should have done this a while ago.

Notifications don't work, I only found your response by comming back to hunt up some threads, if you want, give me your email address so we can keep in touch easier, mine is perriscalderon at gmail
Perris Calderon wrote on Electronic Punk's profile.
Ep, glad to see you come back and tidy up...did want to ask a one day favor, I want to enhance my resume , was hoping you could make me administrator for a day, if so, take me right off since I won't be here to do anything, and don't know the slightest about the board, but it would be nice putting "served administrator osnn", if can do, THANKS

Been running around Quora lately, luv it there https://tinyurl.com/ycpxl
Electronic Punk wrote on Perris Calderon's profile.
All good still mate?
Hello, is there anybody in there? Just nod if you can hear me ...

Forum statistics

Threads
62,030
Messages
673,544
Members
89,039
Latest member
filamnapa