protector330
03-10-2002, 12:37 PM
hello :) could smbdy please help me with a script i do need?
i'm running a chat and some lamers are going on fooling people around by opening 2 chat windows and therefore to access the chat twice at the same time. No further comments about what the do as soon as they are inside twice :mad:
I'd need a java script able to do:
1) check if this user has this url already open
- if yes close the new opened window
- if not leave it open as it is
I've been looking around but did not find anything suiting my needs...
thanks :D
YUPAPA
03-10-2002, 01:01 PM
How about checking if the users have the same IP?
protector330
03-10-2002, 01:04 PM
hi :) yes this is what i was thinking.... wouldn't java suite do make something like this?
p.s. this feature would be nice when none of the operators are online, coz when they are online they take care of this, too :D
Tim Greer
03-10-2002, 02:09 PM
At that point, someone disables JavaScript and you are back where you started. JavaScript is for little extras, but nothing you should ever rely on other than just to provide some extra interaction with their browser. What are you using for this chat, is the question? You can check their IP, but I found quickly when running a chat site myself before, that there are a lot of people at schools/uni's, businesses, etc. that access the cht at the same time. You might be better off using cookies to check, at least in addition with.
protector330
03-10-2002, 02:15 PM
i was thinking about a java script because the entire chat is in java... therfore if somebody wants to override the check, all chat will be overridden :stickout
about ip check... i guess you are right, i did not think about this issue....
but i still need a way to prevent users to access the chat twice... is there a way to get this running with java, but without ip check? i did search around like crazy... no results
thanks in advance!:cartman:
YUPAPA
03-10-2002, 02:18 PM
oooooooooooooooooooh, you know java???
int counter=0;
for(counter=0; counter>0; counter++) {
System.out.println("Hello, I am Yupapa");
}
Tim Greer
03-10-2002, 02:22 PM
Originally posted by protector330
i was thinking about a java script because the entire chat is in java... therfore if somebody wants to override the check, all chat will be overridden :stickout
about ip check... i guess you are right, i did not think about this issue....
but i still need a way to prevent users to access the chat twice... is there a way to get this running with java, but without ip check? i did search around like crazy... no results
thanks in advance!:cartman:
Java and JavaScript are two completely different things. Are you wanting the Java chat applet to detect this somehow? Well, I'm not a big fan of Java or JavaScript, and although they are pretty simple, I don't have a lot of experience with them. Therefore I'll let someone else help with that, but there's definitely a few (probably very simple) ways to do this.
protector330
03-10-2002, 02:38 PM
:cartman: lol yupapa...
hemmm as you see I'm even mixing up java with java scipt... therefore... I'm just good in "Copy&Paste" stuff :rolleyes:
no I will not be able to add this feature to the java chat... directly... but I'm still hoping somebody nice will post the needed java script (as a workaround) in here :D
thanks in advanace :stickout