Jump to content

Google search URLFrame and HTMLFrame


MOGSY

Recommended Posts

  • MOGSY changed the title to Google search URLFrame and HTMLFrame

I had a quick look and found:-

  //////////////////////////////////////////////////////////////////////////////

      '    function sendRequest(data) {'#10+
      '        console.log(data);'#10+
      '        //var URLFrame = Ext.getCmp(''_URLFrame'');'#10+ FAILS ???
      '        var params=[];'#10+
      '        params = ["val="+JSON.stringify(data) ];'#10+
      '        if (params.length > 0) {'#10+
      '            //ajaxRequest(URLFrame, ''findaddress'', params);'#10+ FAILS NO AJAX FUNCTIONS
      '            //ajaxRequest(MainForm.UniURLFrame1, ''findaddress'', params);'#10+ FAILS NO AJAX FUNCTIONS
      '        }'#10+
      '    }'#10+
At least data now goes to console.

  //////////////////////////////////////////////////////////////////////////////

Knowing that ajaxRequest is not implemented I thought you could use:-

  s:= 'ajaxRequest=function ajaxRequest(sender, url, data)'#10+
      '{'#10+
      '}';

  UniURLFrame1.ClientEvents.UniEvents.Add(s);

But need help from Sherzod to implement MainForm.UniURLFrame1, ''findaddress'', params

Link to comment
Share on other sites

Hi Sherzod / Farshad

Is it possible to implement Ajaxrequest fot uniURLFrame?

The issue I have the same code that works good on browser however using uniURLFrame is partially working the map works and the search is good except I can't send result back to UniGui.

The same code in  uniHTMLFrame doest work although it displays the map the search is not working.

If  Leaflet map also initialized at the same time as the UniHTMLFrame, then uniHTMLFrame works 100% and everything works well except there is an error from google complains about two maps.

It appears that UniHTMLFrame requires some additional initialization which I don't know.

Is it possible to advise how can I solve this problem.

We are so close but  need a little magic from UniGui support.

Regards and many thanks for your support.

Link to comment
Share on other sites

8 hours ago, MOGSY said:

uniURLFrame

Hi,

Try with this changes:

function sendRequest(data) {
    var URLFrame = top.Ext.getCmp('_URLFrame');
    var params = [];
    params = ["val=" + JSON.stringify(data)];

    if (params.length > 0) {
        top.ajaxRequest(URLFrame, 'findaddress', params);
    }
}

 

  • Like 1
Link to comment
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
×
×
  • Create New...