we are creating a game and need to open some windows on button clicks,
this does not seem to work on ios safari due to pop-up blocking.
we already looked at other projects and are using the same code as the flappy bird tutorial project.
It seems to work there, but not in ours.
Any help is appreciated, thanks!
Which buttons are meant to open new windows?
the red button at the top is easiest to test, but there are a few. mainly the share buttons on the game over screen.
alright, the solution is found!
apparently it does not work when called after a button press, but it does work when called through an event. The buttons in our example are sprites that fire an event when clicked on, while our project worked with buttons. thanks for taking a look Yaustar.
Nice one in finding the solution and thank you for posting it here.
Yes, as a protection measure, browsers tend to only have operations like this only happen on the event callback.
Surprised that it worked elsewhere with your other method
Very good question and answers. I also found the solution to my problem here, thanks to everyone!