#1639: Add js file to form. Correctly output js settings.