Correct use of string A 'is in' string B?

Keith Clarke keith.clarke at me.com
Wed Oct 14 07:22:56 EDT 2020


Oh, dear - that's embarrassing! Thanks Tore - time to take a break and check for updates on my eyeball firmware! :-D
Best,
Keith

> On 14 Oct 2020, at 12:04, Tore Nilsen via use-livecode <use-livecode at lists.runrev.com> wrote:
> 
> In the url itself you use access_token but in your search you use access_code. May this be the reason for your problems?
> 
> Best regards
> Tore Nilsen
> 
>> 14. okt. 2020 kl. 13:00 skrev Keith Clarke via use-livecode <use-livecode at lists.runrev.com>:
>> 
>> Hi folks,
>> Am I misreading the docs and abusing the 'is in' logic or syntax here...?
>> 
>> In my test case, the browser widget URL takes the form (truncated) https://somewhere.com/callback.lc#access_token=0123456789&...
>> 
>> This is visible in the field "ResponseURL" but the if statement is not firing. 
>> 
>> Is this a syntax or logic error on my part?
>> on browserNavigateComplete
>> 
>> get the URL of widget "Browser" 
>> put it into field "ResponseURL" 
>> 
>> # Update Access Token
>> 
>> put it into tURL
>> 
>> if "access_code" is in tURL then
>> 
>> put tURL
>> 
>> do UpdateAccessToken(tURL)
>> 
>> end if
>> 
>> get the HTMLText of widget "Browser" 
>> 
>> put it into field "Content" 
>> 
>> end browserNavigateComplete
>> 
>> BTW I've also tried the inverse if 'tURL contains 'access_code" 
>> 
>> Thanks & regards,
>> Keith
>> _______________________________________________
>> use-livecode mailing list
>> use-livecode at 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 at lists.runrev.com
> Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
> http://lists.runrev.com/mailman/listinfo/use-livecode





More information about the use-livecode mailing list