Ease of access is one of the top requirements to make a database usable to people. In FileMaker Pro, we’ve created shortcut files that open another database before closing themselves to launch a user directly to a hosted file.
In FileMaker Go we’ve used the Apple configuration utility to create iOS icon shortcuts that launch users into a database using the FMP:// protocol.
Now with FileMaker WebDirect, we have the ability to launch a user to a custom homepage, directly to a database and specify a return URL. If you couple some basic knowledge of creating URL shortcuts with the information below, you can take away a lot of the stress of connecting to your FileMaker WebDirect solutions.
Setting up a custom homepage is a great way to start customizing your FileMaker WebDirect installation. You can refer to the FileMaker WebDirect Guide on page 27 for how to create and place a custom homepage.
If you are going to have regular FileMaker WebDirect users, creating shortcuts for them is essential. You can either add bookmarked URLs to their browser or create desktop shortcuts that launch URLs.
Cool tip: most modern browsers allow you to drag and drop a URL from the address bar to the desktop, automatically creating a shortcut. You can even go one step further and customize the icon for the shortcut to something unique for your solution!
Linking directly to a database
You can link directly to a database by adding # then database_name to the end of your server address. For example, if your server is fm.yoursite.com and you’re opening the server sample file, it would appear as http://fm.yoursite.com/fmi/webd#FMServer_Sample. Note that a forward slash is not required before the pound sign, but it does work if you have it there.
Adding the homeurl parameter
The homeurl parameter allows you to specify a return URL for the user. This is the URL that the user will be directed to when they manually exit, or click a button with the close file, or exit application script steps.
The syntax for this parameter is ?homeurl=_URL. Using our example above, to return the user to www.othersite.com, this would appear as http://fm.yoursite.com/fmi/webd?homeurl=http://www.othersite.com#FMServer_Sample. Note that the pound sign and database name are on the end now. If you leave the pound sign and database name off, it will still take you to the FileMaker WebDirect homepage and honor your homeurl request when you select a database to open.
Creating an auto-login system
So you’ve got the shortcuts set up, URLs written, so what’s next? To make things even easier on your users you could create your own auto-login system. The basic premise is that you create a table to store devices that log the PersistentID of the device. When a user returns, it validates their current PersistentID against the table and logs them in if there is a match.
Note that in FileMaker WebDirect, the PersistentID is changed anytime a user clears their cookies. So FileMaker WebDirect users will need to re-login anytime they clear their cookies. Your users can either be a table, or FileMaker accounts, but if you use FileMaker accounts, you would need to store the user passwords either in a script or table, which might not meet some security guidelines.
We’ve put together a simple-auto login file demonstrating this technique.