iFrame communication question

0 favourites
  • 2 posts
  • I cant post new topic

    i had a some problem here

    I make some games that need to retrieve value from parent iframe

    it should be like this

        window.parent.sendRequest(a+ "=", b, 50, function (response) {
          console.log(response);
        });[/code:3ui4xw25]
    
    I try to make my own behaviour and its look like this
    [code:3ui4xw25]Acts.prototype.sendRequest = function (a, b)
    	{
    		console.log(a);
    		console.log(b);
    		window.parent.sendRequest(a + "=", b , 0, function (response) {
    			console.log(response);
    			this.returnValue = response;
    		});
    	};[/code:3ui4xw25]
    
    and its not work, and when i see inspect element they look like this
    
    TypeError: window.parent.Fo is not a function
    
    why I cant called the function name, and instead c2 call "fo" what is that 

    @

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Up.. up..

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