Archived

This topic is now archived and is closed to further replies.

d000hg

Sorry... but some web-technology questions...

Recommended Posts

Wrong place to post, but we don''t have an appropriate one and this is the most popular so I''ll get more readers! A few questions about web-stuff: 1)Counters - I''d like to know how many hits I''m getting on every page of my site, how many people are looking at screenshots and downloading demos etc. I guess there are (free) solutions, but I wondered if anyone could describe what languages you''d use to do this. I figue some java function can be called when a page is opened which could call a function on the server to log some data, but how do you manipulate data on the server? And this only works for web-pages - how do I monitor someone clicking on download or a screenshot? 2)This links in slightly - how do I make part of my site require a password/login? One that you can''t avoid by finding the url of the page once you get through the login! And how can I host a file so you can''t access it except by clicking on my link on my site? How would I then make this link wrapped in security so you can''t download my game unless the server sees that you''re logged in? Thanks for any help whether very general or language specific.
Read about my game, project #1 NEW (13th August): A new screenshot is up, plus diaries for week #3
John 3:16

Share this post


Link to post
Share on other sites
Give more server info. What server/platform are you on Apache, IIS, Windows, UNIX? Does it support custom CGI scripts? In Perl? Does it support PHP?

For counters. The best way is to analyze the log files, there are all access to any resource logged.

There are a million solutions to your login stuff, but what good is it to have login, when you can access the page without it, just by knowing the URL? And for the download question, you would need to put the file in a password protected diretory, or if you use some sort of session, you need to go through some script (PHP or CGI/perl).

More info needed.

Share this post


Link to post
Share on other sites
I''d give more info but I know almost 0 abou web stuff (I know HTML and java!). The point with the login was it wouldn''t point you to a new page but not load the page until you''d logged in, or something.

What log files?



Read about my game, project #1
NEW (13th August): A new screenshot is up, plus diaries for week #3


John 3:16

Share this post


Link to post
Share on other sites
I assume that you do not run the server yourself, but have (or going to have?) a web space provider. Any good host logs every request that is being made to the server, or virtual server, for the domain. You give these log files to a analyzer of some sort, which will give you the statistics you want. I don''t know of any good one yet, though. I''m not sure either if you eaily can get access to these log files, but any decent provider will, if you ask.

About the login feature. Do you need "real" protection, or just something to keep your grandmother out? You should note that HTTP is a stateless protocol, and have no idea of things as "sessions". You can protect certain directories or files, which will cause the server to send a 401 Access Denied response. When the browser recieves this, it will prompt the user for username/password, which it will then use on further requests below the directory.
The way to deal with "sessions" is to use some sort of scripts (PHP or CGI), that associate a cookie value (put on the vistors computer) or the visitors IP with a user in a database, when the login is made. You can then identify the visitor by that cookie value or the IP. This requires, though, that all protected pages/files are dynamicaly generated.

You need to gather more info, and deside more specifically what you want.

Share this post


Link to post
Share on other sites
quote:
Original post by d000hg
Wrong place to post, but we don''t have an appropriate one and this is the most popular so I''ll get more readers!

Wrong answer! If it doesn''t fit anywhere, it goes in the Lounge. But this one should be in general programming, which is where I''m moving it to.

[ MSVC Fixes | STL | SDL | Game AI | Sockets | C++ Faq Lite | Boost | Asking Questions | Organising code files | My stuff ]

Share this post


Link to post
Share on other sites
quote:
Original post by d000hg
Wrong place to post, but we don''t have an appropriate one and this is the most popular so I''ll get more readers!
A few questions about web-stuff:

1)Counters - I''d like to know how many hits I''m getting on every page of my site, how many people are looking at screenshots and downloading demos etc. I guess there are (free) solutions, but I wondered if anyone could describe what languages you''d use to do this. I figue some java function can be called when a page is opened which could call a function on the server to log some data, but how do you manipulate data on the server? And this only works for web-pages - how do I monitor someone clicking on download or a screenshot?

2)This links in slightly - how do I make part of my site require a password/login? One that you can''t avoid by finding the url of the page once you get through the login! And how can I host a file so you can''t access it except by clicking on my link on my site? How would I then make this link wrapped in security so you can''t download my game unless the server sees that you''re logged in?

Thanks for any help whether very general or language specific.



Read about my game, project #1
NEW (13th August): A new screenshot is up, plus diaries for week #3


John 3:16




1) You can use javascript or PHP or Perl( CGI ) or ColdFusion or any web programming language out there to create a small counter.

2) If you want to have a Login/Password, you need to have some sort of Database or equivalent. Although, you can do it without a database if you''re running on IIS.

This is a bit brief but with the info you gave, I can be any clearer. Give us more info( ie: where you''re hosting your site, do they offer any basic counters or stuff like that ) and we''ll try to give you more specific help.


"DaHjajmajQa''jajHeghmeH!"

Cyberdrek
danielc@iquebec.com
Founder
Laval Linux

/(bb|[^b]{2})/ that is the Question -- ThinkGeek.com
Hash Bang Slash bin Slash Bash -- #!/bin/bash

Share this post


Link to post
Share on other sites