The Content Lookup widget installation has essential parts of setting up this widget project. Make sure to install the Content Lookup widget prior to continuing with the Form installation.
Bootstrap-Datepicker is a library that the form uses for a date picking user interface. You need to obtain a copy of this library and store specific files in your Jive instance for use. Follow these instructions to download the latest version and upload to your community:
- Click Bootstrap-Datepicker download to get the latest version or use a version used by your front end developers.
- (Optional) Perform any required security checks on the downloaded code.
- Extract the zip file to your computer.
- Log into your Jive community.
- Navigate to the upload location for your library files.
- Create an Uploaded File in the Library location of your Jive community. Look in the Bootstrap Datepicker archive on your computer. Expand the dist folder. Expand the css folder. Drag the file "bootstrap-datepicker.min.css" to the file section of the upload. Set the file name to "Bootstrap Datepicker CSS Library", put a description of your choosing, tag it, set the authors, and make sure it is being published to the correct Library location. Click Publish.
- Create another Uploaded File in the Library location of your Jive community. Go back to the Bootstrap Datepicker archive. Go up to the dist folder, and expand the js folder. Drag the file "bootstrap-datepicker.min.js" to the file section of the upload. Set the file name to "Bootstrap Datepicker JavaScript Library", put a description of your choosing, tag it, set the authors, and make sure it is being published to the correct Library location. Click Publish.
jQuery-Placeholder is a library that the form uses for displaying placeholder text in entry fields in browsewrs that do not yet support the placeholder text automatically. You need to obtain a copy of this library and store specific files in your Jive instance for use. Follow these instructions to download the latest version and upload to your community:
- Click jQuery-Placeholder download to get the latest version or use a version used by your front end developers.
- (Optional) Perform any required security checks on the downloaded code.
- Extract the zip file to your computer.
- Log into your Jive community.
- Navigate to the upload location for your library files.
- Create an Uploaded File in the Library location of your Jive community. Drag the file "jquery.placeholder.min.js" from the archive to the file section of the upload. Set the file name to "jQuery Placeholder JavaScript Library", put a description of your choosing, tag it, set the authors, and make sure it is being published to the correct Library location. Click Publish.
- Extract the form widget zip archive to your local computer if you have not done so already.
- Log into your Jive community.
- Navigate to the upload location for your library files.
- Create an Uploaded File in the Library location of your Jive community. Drag the file "form_widget.css" to the file section of the upload. Set the file name to "Form Widget CSS Library", put a description of your choosing, tag it, set the authors, and make sure it is being published to the correct Library location. Click Publish.
- Create another Uploaded File in the Library location of your Jive community. Drag the file "form_widget.js" to the file section of the upload. Set the file name to "Form Widget JavaScript Library", put a description of your choosing, tag it, set the authors, and make sure it is being published to the correct Library location. Click Publish.
- Create an Uploaded File in the Library location of your Jive community. Drag the file "form_widget_builder.css" to the file section of the upload. Set the file name to "Form Widget Builder CSS Library", put a description of your choosing, tag it, set the authors, and make sure it is being published to the correct Library location. Click Publish.
- Create another Uploaded File in the Library location of your Jive community. Drag the file "form_widget_builder.js" to the file section of the upload. Set the file name to "Form Widget Builder JavaScript Library", put a description of your choosing, tag it, set the authors, and make sure it is being published to the correct Library location. Click Publish.
- Use the Content Lookup widget to search for "Library Loader". Click the link to the file in the results. If it is not found, contact your administrator.
- Download a copy of the "Library Loader" file from your community. Open it for editing.
- Go back to the Content Lookup widget and search for "Form Widget". You should see the four library files you uploaded to your community above.
- Find the search result for "Form Widget CSS Library" and copy its Content ID. It should be a number like 694225.
- Update the library_loader.js file line for "form_widget.css" and update the content ID variable (it should be 0 before updating) to the Content ID you just copied. The result should look similar to:
libraries['form_widget.css'] = { contentID: '694225' };
- Find the search result for "Form Widget JavaScript Library" and copy its Content ID. It should be a number like 694226.
- Update the library_loader.js file line for "form_widget.js" and update the content ID variable (it should be 0 before updating) to the Content ID you just copied. The result should look similar to:
libraries['form_widget.js'] = { contentID: '694226' };
- Find the search result for "Form Widget Builder CSS Library" and copy its Content ID. It should be a number like 694227.
- Update the library_loader.js file line for "form_widget_builder.css" and update the content ID variable (it should be 0 before updating) to the Content ID you just copied. The result should look similar to:
libraries['form_widget_builder.css'] = { contentID: '694227' };
- Find the search result for "Form Widget Builder JavaScript Library" and copy its Content ID. It should be a number like 694228.
- Update the library_loader.js file line for "form_widget_bulder.js" and update the content ID variable (it should be 0 before updating) to the Content ID you just copied. The result should look similar to:
libraries['form_widget_builder.js'] = { contentID: '694228' };
- Use the Content Lookup widget to search for "Bootstrap Datepicker". You should see the two library files you uploaded to your community previously.
- Find the search result for "Bootstrap Datepicker CSS Library" and copy its Content ID. It should be a number like 694229.
- Update the library_loader.js file line for "bootstrap-datepicker.css" and update the content ID variable (it should be 0 before updating) to the Content ID you just copied. The result should look similar to:
libraries['bootstrap-datepicker.css'] = { contentID: '694229' };
- Find the search result for "Bootstrap Datepicker JavaScript Library" and copy its Content ID. It should be a number like 694230.
- Update the library_loader.js file line for "bootstrap-datepicker.js" and update the content ID variable (it should be 0 before updating) to the Content ID you just copied. The result should look similar to:
libraries['bootstrap-datepicker.js'] = { contentID: '694230' };
- Use the Content Lookup widget to search for "jQuery Placeholder". You should see the library you uploaded to your community previously.
- Find the search result for "jQuery Placeholder JavaScript Library" and copy its Content ID. It should be a number like 694231.
- Update the library_loader.js file line for "jquery-placeholder.js" and update the content ID variable (it should be 0 before updating) to the Content ID you just copied. The result should look similar to:
libraries['jquery-placeholder.js'] = { contentID: '694231' };
- Save the changes to the library_loader.js file on your computer.
- Edit the "Library Loader" uploaded file in your Jive community.
- Drag the updated file from your computer to the file section of the uploaded file. Click Publish.
You have now updated the Library Loader in your Jive community with the library files needed to run the Form widget.
- Use the Content Lookup widget to search for "jQuery Library". Copy the Content ID. It should be a number like "694224"
- Look in the Form widget archive on your computer and edit the "form_widget_builder.html" file.
- Find the jquery_content_id and replace the zero in the quotes with the Content ID you just copied. The result should look similar to:
var jquery_content_id = "694224";
- Go back to the Content Lookup widget and get the Binary URL for "jQuery Library". It should look similar to:
https://myjiveinstance.mycompany.com/api/core/v3/attachments/file/694224/data
- Edit the "form_widget_builder.html" file again.
- Find the line:
<script src='JQUERY'></script>
replace the text JQUERY with the URL you just copied. It should end up looking similar to:
<script src='https://myjiveinstance.mycompany.com/api/core/v3/attachments/file/694224/data'></script>
- Use the Content Lookup widget to search for "Library Loader". Copy the Content ID.
- Edit the "form_widget_builder.html" file again.
- Find the library_loader_content_id and replace the zero in the quotes with the Content ID you just copied. The result should look similar to:
var library_loader_content_id = "694223";
- Save the file.
- Go to the site you want to put the Form Builder application in your community, and go to the Overview page.
- Manage the Overview page, and drag a new HTML widget onto the page.
- Edit the new HTML Widget.
- Copy the updated code from "form_widget_builder.html" and paste it into the "Your HTML" entry field in the new widget.
- Click "Save Properties".
- Click "Publish Layout".
Your Form Builder is now set up. Site admins can use the below instructions to create their own Forms...
- The starting screen displays an empty form on the left, and a toolbox on the right.
- Continue dragging new elements onto your page, configuring them, and arranging them until you are satisfied with the design.
- Determine where you want your form to post the output documents. This needs to be a location that your target audience must be able to post content, otherwise the form will not be able to submit the form entries for the user. Once decided, go to this location and get the URL of the place.
- Go back to your form design, and click the bottom "Click to set form destination" area.
Once the Form is set up on a page, users can fill out the form and submit entries. Each time a form is submitted, a document is created in the destination with the configured category and tags. The document will contain a table with one row per form element. The first column will contain the field label, and the second column will contain the user's entry.
Note the title of the submitted document is the form name with a timestamp appended to it so the the Jive document name will be unique.If your widget is not working as expected, please review the Issues
- Accordion widget
- Content Lookup
- Content Viewer widget
- Export widget
- Form Report widget
- Menu Bar widget
- Picture Carousel widget
- Presentation widget
- Search widget
- Team Listing widget
If you would like to contribute to this project, please check out Contributing
(c) 2015-2016 Fidelity Investments Licensed under the Apache License, Version 2.0