Jump to content

UniURLFrame


MOGSY

Recommended Posts

Hi

How is possible to send the ajaxrequest from the HTML in uniURLFrame. It is giving errr on "Ext". How should be the function to post request from the uniURLFrame?

If url used how the site should send the ajaxrequest?

    function sendRequest(data) {
        console.log(data);

        varURLFrame = Ext.getCmp('_URLFrame'); 
        var params=[];
        params = ["val="+JSON.stringify(data) ];
        
        if (params.length > 0) {
            ajaxRequest(URLFrame, 'eventName', params);
        }
    }
 

Thank you.

Link to comment
Share on other sites

Hi,

I am actually working on the same thing today. You need a space in  varURLFrame (but I guess you have that).

Additionally in UniEvents

function beforeInit(sender, config)
{
    config.id = '_URLFrame';
}

 

This is where you assign the name that you locate with getCmp.

Hope it helps. It worked for me with the code you had above.

 

Regards, Fredrik.

Edited by Larsson
Typo in id name
Link to comment
Share on other sites

53 minutes ago, MOGSY said:

Hi Fredrik

What you mean by 'You need a space in  varURLFrame'?

 

Regards

image.png

In the pasted code you have varURLFrame = Ext.getCmp('_URLFrame');  

You need to have var URLFrame = Ext.getCmp('_URLFrame'); 
Since you are defining a variable.
 

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...