Skip to content

Data not saving or incomplete - redirection on Prolific #1345

Answered by jodeleeuw
dreamerie asked this question in Q&A
Discussion options

You must be logged in to vote

Hi @dreamerie ,

I believe it's because the data does not have enough time to save before the redirection happens?

Yes, that's probably right.

The optimal fix here would be to wait for the reply from the server that the data has been saved before moving on. I'd need to know more about how your saveData function works to suggest specifics, but it's probably using an XMLHttpRequest. If you can put the redirect inside the callback function from the server request that should solve the issue.

Waiting for 30 seconds would probably work too, but it's also probably way more than what you need to wait for. The callback method will be robust, and result in much shorter wait times for your partici…

Replies: 1 comment 1 reply

Comment options

You must be logged in to vote
1 reply
@dreamerie
Comment options

Answer selected by dreamerie
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants