FileCatalyst Header Logo

HTTP Upload - Integration

Quickstart

It is difficult for this document to provide all integration options. Please contact your account manager to make arrangements for further assistance if required. In short, the common steps to get started as follows:

  1. Copy "{FileCatalyst Server Install Path}\www\httpuploads\" (ie. the parent folder of this very document) to your web server.
  2. Create a page (or update an existing page) to contain an iframe with a valid URL pointing to "formupload_embed.html"
  3. Inspect the file "scripts/config.js" and ensure a proper configuration including valid "server", "port", and "servletLocation" properties. "servletLocation" is commented-out by default, so be sure to un-comment as part of the configuration process. If changes are needed, consider making them with "scripts/config_embed_overrides.js" if the main config file is meant to be shared. You may also provide a username/password for automatic log-in if your scenario permits a shared account.
  4. Ensure environment is well configured (servletLocation and server may be reached, no HTTPS-related security exceptions) and there is end-to-end access from the user's browser to the FileCatalyst Server and its HTTP Servlet.
  5. Ensure that the root URL of your web server is added to the trusted origin list of the HTTP Servlet, as described in FileCatalyst Server's documentation in the section “Enabling Cross-Origin Resource Sharing (CORS) for HTTP Servlet”

Embedding via iframe

You may embed the HTTP Upload user interface into any other web application. The application uses an iframe to help simplify the embedding process. We provide the sample file "index.html" to show how it is done, but it is not a required file; the iframe can be embedded in any webpage. Looking at index.html, we can see how the iframe is embedded via this line:

<iframe src="http://mydomain.com/httpupload/formupload_embed.html" height="480" width="760"></iframe>

Your own iframe will of course use a valid IP or hostname instead of the placeholder "mydomain.com"; in this sample, the "httpupload" folder is found within the web root and contains the HTTP Upload web application.

Since your web server and the HTTP Servlet are at different hostnames, the root URL of your web server must be added to the trusted origin list of the HTTP Servlet, as described in FileCatalyst Server's documentation in the section “Enabling Cross-Origin Resource Sharing (CORS) for HTTP Servlet”

With these steps complete, the otherwise empty page will render the interface:

Required Files

Looking at the iframe's src attribute, we see that it ultimately points to "formupload_embed.html". This file (or a renamed copy) is a required file and is the entry point into the embedded application. To get started with an embedded view, this file along with all its dependencies, must be present on your web server.

The easiest way to ensure the correct files are present is to copy the entire contents of the directory "{FileCatalyst Server Install Path}\www\httpuploads\" to your web server. We do not recommend making edits to formupload_embed.html, as doing so may impact the execution of the application itself.

However, some or all of these files may need editing in order to properly embed the application:

You should be aware that iframes and their contents are subject to restrictions on "mixed content" security measures. You may not serve an insecure formupload_embed.html page (or similar) from within a secured web application; however, you may serve the secure formupload_embed.html from within the insecure parent page.