Jump to content

Recommended Posts

hey guys :D

assume a script takes 30 sec to run completely.  a user will click the button , and the script would run.

now at the 15th sec of the script  , if the user click again on the button (if available) ,  what happens to the previous script ?

 

for example this script ( assume it takes 30 sec , each sql command takes 1 second)

insert into table1(name) value ('name1')
insert into table1(name) value ('name2')
insert into table1(name) value ('name3')
.
.
.

what happens if the user click at the middle of the running script ?

 

 

Link to comment
https://forums.phpfreaks.com/topic/85062-middle-of-a-script/
Share on other sites

I assumed you were talking about a PHP script that does 30 seconds of processing. And, while the page is loading (processing) in a browser, they push the refresh 'button'. This basically means they are issuing an abort, then asking for the page again.

 

What am I missing here?

Link to comment
https://forums.phpfreaks.com/topic/85062-middle-of-a-script/#findComment-433835
Share on other sites

<input type="submit" value="Submit" onclick="this.disabled=true;">

 

that works and i have it on my page , but it is JAVA and can be disabled  , i want to deal with impatience users that got no JAVA .

 

i still don't know what happens if the user click on the submit button in the middle of the previous script running ??? ?

Link to comment
https://forums.phpfreaks.com/topic/85062-middle-of-a-script/#findComment-434328
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.