Jump to content
Claris Engage 2025 - March 25-26 Austin Texas ×

This topic is 3334 days old. Please don't post here. Open a new topic instead.

Recommended Posts

Posted

Hey Guys,

Do any of you know if I can use the open url command (or any other FileMaker command) to open a webpage on its own as a pop up and not as a tab. Ideally I need to inject some javascript (which I have) wrapped around the web address. I've tried to inject javascript with the open URL script but I've had no luck. I have also tried to created a button in the web viewer and when the user clicks on that, I'm assuming it opens another tab in the web viewer, as thats where the scope of the button was. Of course I can't debug this as FileMaker WebViewer doesn't have any built in debug tools for javascript (Windows - I.E) 

I've got the javascript method figured out as I can do it via a html page, but anyone else found a way to create a button on a FileMaker layout which can open a web browser execute javascript.

window.open("http://www.w3schools.com""_blank""toolbar=yes, scrollbars=yes, resizable=yes, top=500, left=500, width=400, height=400");

 

 

Thanks

Jalz 

Posted (edited)

Yeah - you have do a bit of a work around:

1) Compile a HTML document that gives you the exact results you want.
2) You will need to Copy that HTML into a global field 
3) Export the contents of that field to your TEMP directory (open automatically)

See this attached sample file. I deal with the Redirect, window position, and window size. Did not take the time to deal with other characteristics of the window (because of browser compatibility issues. I will leave that up to you ;-)

BTW - this could be revamped so the HTML you are exporting can be a function where you can re-user it feeding VARS to the various parameters. This is really to get to creativity wheel moving.

Hope this helps!

dwdc_launchUrl.fmp12

Edited by dwdata
Posted

Thanks for the sample file DWData - I'll explore and see how I get on :)

This topic is 3334 days old. Please don't post here. Open a new topic instead.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.