Link to Mod Share Mod Share

  Users Browse Upload Forums Log in

Mod Share Forums

Welcome to the Mod Share forums.

You are not logged in.

#1 2012-12-28 11:09:57

Molybdenum
Mod Share-er
From: IDK
Registered: 2012-11-24
Posts: 256

Prevent sending more than one comment every 5 seconds

To prevent double/triple miscomments.

Support?

  1. Yes
  2. No
Total votes: 4

Results of poll are hidden from guests


Please help! Free ads on my next project on Scratch for helpers! Love-its on your 5 most recent projects (also with ads) for people who fix the entire problem!
ALL THESE WORLDS ARE YOURS - EXCEPT EUROPA - ATTEMPT NO LANDING THERE / I've quit MS. Why? ":P". Feel free to land on Europa now, and you might contact me at intf.tk or intforums.com, but remember the 49 minute time lag between Europa and Earth.
x8HDw.gif
SHA-256 confirmation

Offline

#2 2012-12-28 11:43:58

jvvg
Mod Share Team
From: United States
Registered: 2012-09-16
Posts: 616
Website

Re: Prevent sending more than one comment every 5 seconds

Or, just only click the button once. tongue


wr5t1.png2h6dij7.png293kn7c.jpg2lwke37.png
Programmer • Runner • Mod Share Admin

Offline

#3 2012-12-28 12:06:18

Molybdenum
Mod Share-er
From: IDK
Registered: 2012-11-24
Posts: 256

Re: Prevent sending more than one comment every 5 seconds

jvvg wrote:

Or, just only click the button once. tongue

Sometimes, we assume the comment was not sent, and don't want to refresh (like if we are using the project), and click it again tongue


Please help! Free ads on my next project on Scratch for helpers! Love-its on your 5 most recent projects (also with ads) for people who fix the entire problem!
ALL THESE WORLDS ARE YOURS - EXCEPT EUROPA - ATTEMPT NO LANDING THERE / I've quit MS. Why? ":P". Feel free to land on Europa now, and you might contact me at intf.tk or intforums.com, but remember the 49 minute time lag between Europa and Earth.
x8HDw.gif
SHA-256 confirmation

Offline

#4 2012-12-28 13:24:52

jvvg
Mod Share Team
From: United States
Registered: 2012-09-16
Posts: 616
Website

Re: Prevent sending more than one comment every 5 seconds

Molybdenum wrote:
jvvg wrote:

Or, just only click the button once. tongue

Sometimes, we assume the comment was not sent, and don't want to refresh (like if we are using the project), and click it again tongue

You don't need to refresh...
It uses AJAX and automatically gets the new comments.


wr5t1.png2h6dij7.png293kn7c.jpg2lwke37.png
Programmer • Runner • Mod Share Admin

Offline

#5 2012-12-28 13:29:19

Molybdenum
Mod Share-er
From: IDK
Registered: 2012-11-24
Posts: 256

Re: Prevent sending more than one comment every 5 seconds

jvvg wrote:
Molybdenum wrote:
jvvg wrote:

Or, just only click the button once. tongue

Sometimes, we assume the comment was not sent, and don't want to refresh (like if we are using the project), and click it again tongue

You don't need to refresh...
It uses AJAX and automatically gets the new comments.

The comment may not be displayed sometimes (ex. high cpu usage, bad connection). This happened on Scratch before.


Please help! Free ads on my next project on Scratch for helpers! Love-its on your 5 most recent projects (also with ads) for people who fix the entire problem!
ALL THESE WORLDS ARE YOURS - EXCEPT EUROPA - ATTEMPT NO LANDING THERE / I've quit MS. Why? ":P". Feel free to land on Europa now, and you might contact me at intf.tk or intforums.com, but remember the 49 minute time lag between Europa and Earth.
x8HDw.gif
SHA-256 confirmation

Offline

#6 2012-12-28 13:31:11

jvvg
Mod Share Team
From: United States
Registered: 2012-09-16
Posts: 616
Website

Re: Prevent sending more than one comment every 5 seconds

Molybdenum wrote:
jvvg wrote:
Molybdenum wrote:

Sometimes, we assume the comment was not sent, and don't want to refresh (like if we are using the project), and click it again tongue

You don't need to refresh...
It uses AJAX and automatically gets the new comments.

The comment may not be displayed sometimes (ex. high cpu usage, bad connection). This happened on Scratch before.

I implemented code where after you submit a comment, you can't submit any more until the comment is displayed.


wr5t1.png2h6dij7.png293kn7c.jpg2lwke37.png
Programmer • Runner • Mod Share Admin

Offline

#7 2012-12-28 13:33:46

Molybdenum
Mod Share-er
From: IDK
Registered: 2012-11-24
Posts: 256

Re: Prevent sending more than one comment every 5 seconds

jvvg wrote:
Molybdenum wrote:
jvvg wrote:

You don't need to refresh...
It uses AJAX and automatically gets the new comments.

The comment may not be displayed sometimes (ex. high cpu usage, bad connection). This happened on Scratch before.

I implemented code where after you submit a comment, you can't submit any more until the comment is displayed.

That's good smile


Please help! Free ads on my next project on Scratch for helpers! Love-its on your 5 most recent projects (also with ads) for people who fix the entire problem!
ALL THESE WORLDS ARE YOURS - EXCEPT EUROPA - ATTEMPT NO LANDING THERE / I've quit MS. Why? ":P". Feel free to land on Europa now, and you might contact me at intf.tk or intforums.com, but remember the 49 minute time lag between Europa and Earth.
x8HDw.gif
SHA-256 confirmation

Offline

#8 2012-12-29 15:15:43

LS97
Mod Share Team
Registered: 2012-01-14
Posts: 218

Re: Prevent sending more than one comment every 5 seconds

Jacob, I think it's better to implement a flood prevention of 40 seconds between comments.


LS97 - Mod Share Admin

Offline

#9 2012-12-29 18:37:28

jvvg
Mod Share Team
From: United States
Registered: 2012-09-16
Posts: 616
Website

Re: Prevent sending more than one comment every 5 seconds

LS97 wrote:

Jacob, I think it's better to implement a flood prevention of 40 seconds between comments.

That would be rather difficult to code, though. The way the current AJAX code works, it would be difficult.


wr5t1.png2h6dij7.png293kn7c.jpg2lwke37.png
Programmer • Runner • Mod Share Admin

Offline

#10 2012-12-30 14:16:46

LS97
Mod Share Team
Registered: 2012-01-14
Posts: 218

Re: Prevent sending more than one comment every 5 seconds

jvvg wrote:
LS97 wrote:

Jacob, I think it's better to implement a flood prevention of 40 seconds between comments.

That would be rather difficult to code, though. The way the current AJAX code works, it would be difficult.

Add a "last comment time" field to the database for each user and check whether that time + 40s has gone by. Just make sure the user-side code retains a copy of the comment until it receives a 200 "all good" reply.

Not too difficult.


LS97 - Mod Share Admin

Offline

#11 2013-02-19 18:02:11

Molybdenum
Mod Share-er
From: IDK
Registered: 2012-11-24
Posts: 256

Re: Prevent sending more than one comment every 5 seconds

I don't think this works in some cases - Today I commented, the comment area froze, I clicked again assuming it didn't work, and a few seconds later, both comments came up.


Please help! Free ads on my next project on Scratch for helpers! Love-its on your 5 most recent projects (also with ads) for people who fix the entire problem!
ALL THESE WORLDS ARE YOURS - EXCEPT EUROPA - ATTEMPT NO LANDING THERE / I've quit MS. Why? ":P". Feel free to land on Europa now, and you might contact me at intf.tk or intforums.com, but remember the 49 minute time lag between Europa and Earth.
x8HDw.gif
SHA-256 confirmation

Offline

#12 2013-02-19 19:11:27

jvvg
Mod Share Team
From: United States
Registered: 2012-09-16
Posts: 616
Website

Re: Prevent sending more than one comment every 5 seconds

Yeah, I saw that. I'll check the code as soon as I can (which is tomorrow).


wr5t1.png2h6dij7.png293kn7c.jpg2lwke37.png
Programmer • Runner • Mod Share Admin

Offline

Board footer

This is part of Mod Share v4.0