This is version . It is not the current version, and thus it cannot be edited.
[Back to current version]   [Restore this version]

OK, here is how to do this. Place the disclaimer in a file called "disclaimer.html" and put it in the WebInterface folder of CrushFTP.

Make a new form in the server preferences WebInterface, and add three items.

The first item must be a checkbox, or text field, etc. Some value the user must have the option to modify as the browser will auto select this when the page loads. So maybe the persons name they must fill in, or have two checkboxes required to confirm reading the form, etc. One at the top, and bottom.

Second item is a label. The "Left" text is: (copy and paste this, it will get merged into one line.)

<script>
$.get("/WebInterface/disclaimer.html", function(data){$("td:contains('Disclaimer')").html(data);});
$("#welcomeFormPanel").css("height","400px");
$("#welcomeFormPanel").css("overflow-y","scroll");
$("#welcomeFormPanel").css("overflow-x","hidden");
</script>

The "Right" text must be the word "Disclaimer".

Then add a third item to the form, a checkbox.

Left label is blank.

1 checkbox.

Checkbox wording is: "I confirm I have read and agree to the terms."

Require this item.

That's it. Once you scroll to the bottom, you get the checkbox that you must check to be able to click "OK" or else the OK button will tell you you must check it.

The magic is in the "script" that is the left text of the label. This script loads the disclaimer and inserts it in place of the "Disclaimer" static text. It then enables scrolling vertically, and hides horizontal scrolling. Sets the height, and its done.

Add new attachment

Only authorized users are allowed to upload new attachments.
« This particular version was published on 09-Oct-2016 18:14 by Ben Spink.
G’day (anonymous guest)

OLD WIKI!!!#

New: CrushFTPv9#

OLD WIKI!!!#


CrushFTP8 | What's New

Referenced by
UserManagerWebInterface

JSPWiki