LF Forms has a 2000 character limit for CSS, and I’ve just hit that. Is it possible to use External Style sheets? If so, what’s the appropriate location to store the sheet and where would I call the sheet from? I’ve tried making the call from the Script page after copying all the CSS into the external style sheet but that doesn’t seem to work.
Question
Question
Answer
The 2000 character limit for both CSS and JavaScript will be removed in Forms 9.1.
For now, it is fairly straightforward to include an external CSS file reference.
On the machine hosting the Forms Server, navigate to C:\Program FIles (x86)\Laserfiche\Laserfiche Forms\Forms\js.
Put your css file there.
Add the following code to the JavaScript section of the Script page for the form:
Code: |
|
Replies
Can this be done with Javascript as well? I knew about adding in javascript libraries to a folder on the server but did not know to add a javascript function for adding the library.
Also, what is stopping you from inserting a custom HTML field with the reference to the CSS stylesheet?
Yes, you can also include external JavaScript references.
See http://www.laserfiche.com/support/webhelp/laserficheforms/9.0/en-us/forms/#CustomizingYourFormExamples.htm#IncludingExternalJavaScriptFiles for more information.