Skip to main content

FAQ Part 7: URL Plug-in questions

By December 1, 2017May 20th, 2018FAQ

Can you use Troi URL Plug-in to access a file hosted with the Web Companion?

Yes, this is possible. However, it won’t work always if you are trying to access a URL on the same computer. This is the case if you use the same FileMaker Pro Client for the Web Companion and Troi URL Plug-in.

How do I use Troi URL Plug-in in combination with a proxy server?

You can explicitly set the proxy with the TURL_SetProxy function. If you don’t use this function the system settings for proxies will be used.

Can Troi URL Plug-in manage and set cookies?

Yes, you can use the TURL_SetCookies function to set the cookies text on Mac OS. On Windows cookies are handled natively by the operating system, so this function does not do anything on this platform.
See also the example files in the URL Plug-in download for more information.

My TURL_Post command works on Mac OS but not on Windows (or vice versa). What gives?

When the same command works on Mac but not on Windows this probably has to do with the encoding. On Windows the default header is “application/x-www-form-urlencoded” and on Mac “NotEncoded” is the default. When your Post works on Mac but not on Windows, please try adding (on Windows) the switch -NotEncoded to the Post function, like this:

TURL_Post ( "-NotEncoded" ; theURL ; theData )

When your Post works on Windows but not on Mac, you should (on Mac) first set a custom header:

TURL_SetCustomHeader ( "-unused" ; "Content-Type: application/x-www-form-urlencoded" )

and then do the TURL_Post step.

Which SSL certificates are used by Troi URL Plug-in?

The plug-in uses the certificates that the OS has installed.

How can the URL plug-in send the data of radio buttons and checkboxes in a form?

With the URL plug-in you can also post forms that have radio buttons or checkboxes in it.
Say you have this web page with a FORM on it:

<P><INPUT TYPE=checkbox NAME=checkbox1 VALUE=value1 CHECKED>checklabel</P>
<P><INPUT TYPE=radio NAME=myradio VALUE=radiovalue1>radiolabel 1
<INPUT TYPE=radio NAME=myradio VALUE=radiovalue2>radiolabel 2</P>
<P>input data:<INPUT TYPE=text NAME=field1 VALUE="" SIZE=32><BR>
<INPUT TYPE=submit NAME=Submit VALUE="Submit for Processing"></P>

This FORM has a checkbox, 2 radio buttons and an input field.

In the POST data you only include the checkbox if it is checked. Otherwise leave it out. When you add it, add the name, in this case “checkbox1”, an equals sign and the value, here “value1”.
So in the case above you add: “checkbox1=value1” for this checked box.

For a radiobutton you include the value of the radiobutton that is selected. In this example “myradio”, an equals sign and the value of the chosen radiobutton, here “radiovalue2”.

Putting it together you need to send this as the POST data (the 3rd parameter):


NOTE Spaces are not allowed, so you need to encode these as %20. Also other higher ASCII characters need to be encoded. You can use the TURL_ToHTTP function of the plug-in to do this.

How can I see what POST data is sent to a web server?

HTTP requests are never displayed to the user. If you want to see them, you need to use tools such as the Firefox Web Console, Chrome Developer Tools or Fiddler.

Other questions?

If your question is not answered here, please look in the documentation that comes with the plug-in. If you have suggestions please email a FAQ suggestion.