Search code examples
javascriptphppromiseurl-shortener

How to get a response from another window in the browser?


I have a website which provide for user doing some offers and get paid when he finish them, I want to add short urls, when the user click on it and go to it and wait seconds and skip the ads.., after he finish i get response that he really finish the pages and don't live from the first second


Solution

  • make an event listener that's listen to the video so that when it reaches the end it saves data (ex: true) to your database which indicates that the user finished watching the whole video, you can also prevent the user from seeking the video (for him not skipping any part of the video). hope this will help you.