Jump to content
View in the app

A better way to browse. Learn more.

FMForums.com

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Redirect from item on stock FM WebD launch page

Featured Replies

Hello,

We use the default WebDirect Launch Center page for our apps. (FMS 16)  I'm wondering if there might be a way to override the destination of individual items.  I'm working on updating/migrating to a new server, and would like to do it one file at a time, as I'm able to, without the users having to do anything different.  For example, users go to the WebD page on ServerA, click the icon for File1, and have the browser actually go to ServerB/fmi/webd/NewFile.

Is this possible, aside from creating a custom home page (which would throw off the users)?

  • 2 weeks later...
  • Author

Success!

If you inspect the file icons on the WebDirect launch page using the browser tools, it looks like you'd have to monkey with Java code in order to override anything.  However, realizing that you can get to a file at the URL "/fmi/webd/DBNAME", I thought FM must be simply issuing an HTTP request in their Java, and wondered if a simple Apache redirect might do it.  Turns out, it works!

Here's what I did --

Old server:  Mac Mini running macOS Sierra (10.12.6), FileMaker Server 16

New server: Ubuntu 22 server, FileMaker Server 21.1.1.40

On the old server, edit the file /Library/FileMaker Server/HTTPServer/conf/httpd.conf and at the end of the file add:

#Redirect to new server
<Location "/fmi/webd/myFMDB">
  Redirect "https://newserver/fmi/webd/myFMDB?homeurl=https://oldserver/fmi/webd"
</Location>

The "homeurl" parameter in the redirect URL makes it so that the user will come back to the original WebD launch page when they close the file on the new server.  Other than the URL in the browser, the user shouldn't notice a difference.  And if you wanted to do a fancier redirect with URL rewriting, you could do a pass-thru of the original URL.

In order to get the "homeurl" feature to work, you have to edit a file on the new server.  Edit the file /opt/FileMaker/FileMaker Server/Web Publishing/conf/jwpc_prefs.xml and update these values:

<parameter name="homeurlenabled">yes</parameter>
<parameter name="customhomeurl">https://oldserver</parameter>

Enter only the domain for the "customhomeurl" parameter!  This tripped me up for a while.  I had entered "https://oldserver/fmi/webd", but it wouldn't work.  Gotta read all the notes!  See this page from Claris.

Now that that's done (don't forget to restart WPE on the new server with "fmsadmin restart wpe") you can bounce Apache on the old server.  Use this to avoid disrupting currently connected users:

sudo /Library/FileMaker\ Server/HTTPServer/bin/httpdctl graceful

Your redirect should now be working!

One other thing that tripped me up - if your FM file has spaces in the name, don't use the %20 code in your Location tag in the Apache conf.  Just do:

<Location "/fmi/webd/My File With Spaces">

 

Hope this helps somebody!

Create an account or sign in to comment

Important Information

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

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.