/    Sign up×
Community /Pin to ProfileBookmark

IP-adress, writing, reading

Hi,
I’m making a home page, on which my students can solve problems. Of course I can keep score using cookies, but that way only the students themselves can access that information.

I thought of the following:
When they visit my site for the first time, they register on a form (name, class, e-mail)
I give them an ID-number cookie or (even better) read their IP-address.
This IP-addres or ID is then written to a file together with their name, class, e-mail AND achievements. The next time they log on, they are recognized via their ID-number cookie or IP-address. All problems that they already solved will not appear then.

Moreover, I myself can see the progress, and I can see which students are using my home page at all.

I cannot find a way to do this in JavaScript, but is it possible? And if not, what should I use then? (Hopefully I do not need to learn another language as well)

I know that if I didn’t need to follow the progres myself, I could do it with cookies. But I DO need to follow the progress.
Of course this can be done, the question is: How?

Please reply if you can help me any further. I’m stuck.

to post a comment
JavaScript

3 Comments(s)

Copy linkTweet thisAlerts:
@NicodemasFeb 25.2003 — I'm afraid it will require a server side technology to do what you are suggesting. ASP and PHP are good starts. Since Javascript is a client-side language, it does not "save" information for you.

Also, IP addresses are constantly changing today's internet world. If two or more of your students access the web via the same internet provider, then there could be some confusion in IP Address assignment.

Regardless, you'll need a backend database system in order to accomplish what you want. Sorry.
Copy linkTweet thisAlerts:
@khalidali63Feb 25.2003 — You can probably get away with getting IP-addresses using signed applets.(you can use Java directly in NS browsers to do get IP address).

Cheers

Khalid
Copy linkTweet thisAlerts:
@NevermoreFeb 25.2003 — I would recommend using a log on/register script written in PHP or ASP, and not IP addresses, because your IP address changes, in most cases, every time you connect to the internet. If you need some help in PHP, I'll do my best, but your server may not support it. You will also need a database package on the server, e.g. MySQL, which is free for most use.
×

Success!

Help @Ritz spread the word by sharing this article on Twitter...

Tweet This
Sign in
Forgot password?
Sign in with TwitchSign in with GithubCreate Account
about: ({
version: 0.1.9 BETA 5.19,
whats_new: community page,
up_next: more Davinci•003 tasks,
coming_soon: events calendar,
social: @webDeveloperHQ
});

legal: ({
terms: of use,
privacy: policy
});
changelog: (
version: 0.1.9,
notes: added community page

version: 0.1.8,
notes: added Davinci•003

version: 0.1.7,
notes: upvote answers to bounties

version: 0.1.6,
notes: article editor refresh
)...
recent_tips: (
tipper: @AriseFacilitySolutions09,
tipped: article
amount: 1000 SATS,

tipper: @Yussuf4331,
tipped: article
amount: 1000 SATS,

tipper: @darkwebsites540,
tipped: article
amount: 10 SATS,
)...