Announcement

Collapse
No announcement yet.

How do you display 'Editor' type field as read only

Collapse
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • How do you display 'Editor' type field as read only

    I would like my form to disallow editing in an editor-type field when not in insert/ modify mode. Switching it to label type simply displays the raw html.

  • #2
    2 choices as I see it:

    Easiest way is to use the "Disabled" setting for the field (just under "Label field") - you can say whether that field is disabled when in insert or update or both mode.

    Or

    Create a new text field (as a label field) that is populated with cleaned up text (maybe via a small function you create - must be loads of examples you can find with google). And then, depending on the form's mode, hide the text field or the label field.

    Comment


    • #3
      Originally posted by adz1111 View Post
      2 choices as I see it:

      Easiest way is to use the "Disabled" setting for the field (just under "Label field") - you can say whether that field is disabled when in insert or update or both mode.

      Or

      Create a new text field (as a label field) that is populated with cleaned up text (maybe via a small function you create - must be loads of examples you can find with google). And then, depending on the form's mode, hide the text field or the label field.
      For this field type, I had chosen the option "insert/ update mode" for "Disabled Field" setting but it has no effect.

      Right now I'm doing something akin to your second option using a temporary text field and hiding the editor field: ob_start(), echo, ob_get_contents() and then ob_end_clean();

      Clumsy but works roundabout.

      Thanks

      Comment


      • #4
        Originally posted by scriptcaser View Post
        I would like my form to disallow editing in an editor-type field when not in insert/ modify mode. Switching it to label type simply displays the raw html.
        Did you checked "show HTML content" on this field?
        /Giuseppe

        Professional Scriptcase Services
        Some Customers opinions

        Comment


        • #5
          Originally posted by Giu View Post
          Did you checked "show HTML content" on this field?
          I find no such option for HTML Editor type nor for label type. Where is this?

          Comment


          • #6
            Giu

            Think that option is only on grids..

            Comment

            Working...
            X