If you mean using merge inside the function, I guess one could do the merge
beforehand and pass it in as a parameter, or alternatively do the merge in
the function and return the generated url string as part of the returned
value.  IE change it like so..
function translate pText,pLang
   put merge(kGetTransUrl) into tUrl
   get url tUrl
   return "URLString: " & tUrl & cr & it
end translate

Then just dump the first line if things are working right.  Hmm. Actually,
pre-merging is nice because it would allow the use of "load" with callbacks
for multiple url calls. Use the callback to process, part of which lets you
see the URL associated with the callback.  Sounds like a better option than
using a function call for sure.

On Fri, Jun 15, 2018 at 2:54 PM Bob Sneidar via use-livecode <
use-livecode@lists.runrev.com> wrote:

> Again, this is why I don't like to nest functions. You cannot tell what
> the function returned without pulling it apart.
>
> Bob S
>
>
> > On Jun 15, 2018, at 10:40 , Mike Bonner via use-livecode <
> use-livecode@lists.runrev.com> wrote:
> >
> > jsontoarray returns an array, you'll have to dig through the array to
> find
> > where pieces of information reside, but it pretty straightforward after
> you
> > poke around.
> >
> > For example.. If you instead do this..
> > put jsontoarray(tResult) into tArray
> >
> > you have an array variable named tArray.
>
>
> _______________________________________________
> use-livecode mailing list
> use-livecode@lists.runrev.com
> Please visit this url to subscribe, unsubscribe and manage your
> subscription preferences:
> http://lists.runrev.com/mailman/listinfo/use-livecode
>
_______________________________________________
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode

Reply via email to