| Reference | Downloads | Github

Experiment content cannot be displayed

Description of the problem: In this experiment, I want to collect participants’ demographic information at the beginning and then use this information to customise the instructions later. However, after entering the demographics, the webpage just turned to black screen and no following texts and contents would be showed even after a long waiting time… could anyone help me view the code and see where the problems are? many thanks in advance!

Hi @sean0820, this is because of the custom code:

while (blockLen_1 < 5 || blockLen_1 > 15){
	  blockLen_1 = expDis (10);

The expDis (10) function always returns values less than 5, and so your while loop does not break.

Hi @dvbridges, many thanks for your help! I’ve sloved the loop issue. However, i came across some other problems… Specically, as you can see in the code (e.g. line 2099), i want to move the image stimuli by mouse click. The code can work well on my firefox browser, but not my safari one… Second, in the task, i want to provide participants feedback each trial based on their perofrmance (hit or miss). There are multiple blocks in the experiment, and the feedback code can work in the first block (line 2178) but not the later ones (e.g. line 3141) even though the code is the same. Do you know how to solve these probelms?