Pop up protection!

0 favourites
  • 7 posts
From the Asset Store
Relax and relieve stress by popping bubbles in Fidget Anti- Stress Releaser!
  • Hi,

    I have an event triggering a "open new window" URL

    This however always triggers the Popup protection message.

    Is there a way to make a new window open like a regular LINK?

  • The best thing you can do is make sure you open a window in a user input event, like 'On mouse button clicked' or 'On key pressed'. Hopefully then the browser recognises that the window opening is an action the user intended, and not some spammy popup advert.

    However, this doesn't always work - spammers still use the same method for opening popups. So some browsers (Firefox especially IIRC) will simply block all window opens anyway, and the user must approve it by clicking the notification. Users are probably fairly used to this. So you can either just have a note (e.g. "Warning: opens new window") so the user knows when they see the "popup blocked" it was actual content rather than some popup ad. Or you can just navigate the current page - that will end the game, but it always works. Or, just put the hyperlink in the page HTML outside your game.

    This is more of a general problem with web development than anything specific to C2 - everyone hates popups, and if you try to open a new window, you're at the mercy of popup blockers.

  • Thank you Ashley,

  • I had the same problem too and fix it with.

    Mouse button released

    Mause cursor is over sprite     Browser goes to http:// in new windows.

    This works great

  • legora THANK YOU!!!!!

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • legora: You might prefer using a single condition ->

    "Mouse: on object clicked 'Sprite'".

  • It is better if you want to open URL in the same window, but when you want to open it in new window Firefox shows pop up protection, on chrome and IE works fine i think.

Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)