Support

Account

Home Forums Search Search Results for 'Wysiwyg'

Search Results for 'Wysiwyg'

reply

  • If that did not have an effect then the issue is likely with a filter on the site.

    It could be an acf/load_field filter or an acf/load_value filter. This issue could also have something to do with a shortcode on the site and what shortcodes are inserted into this wysiwyg.

    Beyond this you are pretty much on your own.

  • I’ve got a quick fix for this, but it’s not ideal. The problem is that Ninja Forms creates a unique modal that is associated specifically the main content region, and it doesn’t support multiple of that modal of one page. When ACF is installed, the modal gets duplicated to account for custom WYSIWYG fields, but that causes a bunch of issues due to the duplication.

    Simple solution is to just remove the fields from ACF fields. Obviously this means you need to manually insert Ninja Forms when using custom fields, but it’s a reasonable compromise.

    
    add_action("admin_head", function () {
    ?>
    <style type="text/css">
    #nf-insert-form-modal .ui-icon {
        display: inline-block;
        text-indent: 0;
    }
    </style>
    <?php
    });
    
    add_action("admin_footer", function () {
    ?>
    <script type="text/javascript">
    window.addEventListener("DOMContentLoaded", () => {
        const ACFS = document.querySelectorAll("#acf-hidden-wp-editor, .acf-field-wysiwyg");
    
        ACFS.forEach((acf) => {
            const FORM  = acf.querySelector(".button.nf-insert-form");
            const STYLE = acf.querySelector("#nf-insert-form-modal + style");
            const MODAL = acf.querySelector("#nf-insert-form-modal");
    
            if (FORM) {
                FORM.remove();
            }
    
            if (STYLE) {
                STYLE.remove();
            }
    
            if (MODAL) {
                MODAL.remove();
            }
        });
    });
    </script>
    <?php
    });
  • If it helps you, import this as “something.json” in your ACF and check it out.

    [
        {
            "key": "group_5d75feeccbdc9",
            "title": "Spalten",
            "fields": [
                {
                    "key": "field_5d725da67101e",
                    "label": "Spalten",
                    "name": "columns",
                    "type": "flexible_content",
                    "instructions": "",
                    "required": 0,
                    "conditional_logic": 0,
                    "wrapper": {
                        "width": "",
                        "class": "",
                        "id": ""
                    },
                    "layouts": {
                        "layout_5d720da0975d2": {
                            "key": "layout_5d720da0975d2",
                            "name": "columns_row_row_h2",
                            "label": "Headline (H2)",
                            "display": "block",
                            "sub_fields": [
                                {
                                    "key": "field_5d725da671025",
                                    "label": "Text",
                                    "name": "text",
                                    "type": "text",
                                    "instructions": "",
                                    "required": 0,
                                    "conditional_logic": 0,
                                    "wrapper": {
                                        "width": "",
                                        "class": "",
                                        "id": ""
                                    },
                                    "acfe_permissions": "",
                                    "default_value": "",
                                    "placeholder": "",
                                    "prepend": "",
                                    "append": "",
                                    "maxlength": "",
                                    "acfe_validate": false,
                                    "acfe_update": false
                                }
                            ],
                            "min": "",
                            "max": ""
                        },
                        "layout_5d720ea2b59b6": {
                            "key": "layout_5d720ea2b59b6",
                            "name": "columns_row_row_h3",
                            "label": "Headline (H3)",
                            "display": "block",
                            "sub_fields": [
                                {
                                    "key": "field_5d725da67102c",
                                    "label": "Text",
                                    "name": "text",
                                    "type": "text",
                                    "instructions": "",
                                    "required": 0,
                                    "conditional_logic": 0,
                                    "wrapper": {
                                        "width": "",
                                        "class": "",
                                        "id": ""
                                    },
                                    "acfe_permissions": "",
                                    "default_value": "",
                                    "placeholder": "",
                                    "prepend": "",
                                    "append": "",
                                    "maxlength": "",
                                    "acfe_validate": false,
                                    "acfe_update": false
                                }
                            ],
                            "min": "",
                            "max": ""
                        },
                        "layout_5d6f7653437a2": {
                            "key": "layout_5d6f7653437a2",
                            "name": "columns_row_row_intro",
                            "label": "Einleitung",
                            "display": "block",
                            "sub_fields": [
                                {
                                    "key": "field_5d725da671033",
                                    "label": "Editor",
                                    "name": "columns_row_row_intro_editor",
                                    "type": "wysiwyg",
                                    "instructions": "",
                                    "required": 1,
                                    "conditional_logic": 0,
                                    "wrapper": {
                                        "width": "",
                                        "class": "",
                                        "id": ""
                                    },
                                    "acfe_permissions": "",
                                    "default_value": "",
                                    "tabs": "all",
                                    "toolbar": "full",
                                    "media_upload": 0,
                                    "delay": 0,
                                    "acfe_validate": false,
                                    "acfe_update": false
                                }
                            ],
                            "min": "",
                            "max": ""
                        },
                        "577ba52f12d8c": {
                            "key": "577ba52f12d8c",
                            "name": "columns_row_row_wysiwyg",
                            "label": "Editor",
                            "display": "block",
                            "sub_fields": [
                                {
                                    "key": "field_5d725da67103a",
                                    "label": "Editor",
                                    "name": "columns_row_row_wysiwyg_editor",
                                    "type": "wysiwyg",
                                    "instructions": "",
                                    "required": 1,
                                    "conditional_logic": 0,
                                    "wrapper": {
                                        "width": "",
                                        "class": "",
                                        "id": ""
                                    },
                                    "acfe_permissions": "",
                                    "default_value": "",
                                    "tabs": "all",
                                    "toolbar": "full",
                                    "media_upload": 0,
                                    "delay": 0,
                                    "acfe_validate": false,
                                    "acfe_update": false
                                }
                            ],
                            "min": "",
                            "max": ""
                        },
                        "layout_5d6f7c304ec2a": {
                            "key": "layout_5d6f7c304ec2a",
                            "name": "columns_row_row_card",
                            "label": "Karte",
                            "display": "block",
                            "sub_fields": [
                                {
                                    "key": "field_5d725da671041",
                                    "label": "Bild",
                                    "name": "columns_row_row_card_img",
                                    "type": "image",
                                    "instructions": "",
                                    "required": 0,
                                    "conditional_logic": 0,
                                    "wrapper": {
                                        "width": "",
                                        "class": "",
                                        "id": ""
                                    },
                                    "acfe_permissions": "",
                                    "return_format": "array",
                                    "preview_size": "thumbnail",
                                    "library": "all",
                                    "min_width": "",
                                    "min_height": "",
                                    "min_size": "",
                                    "max_width": "",
                                    "max_height": "",
                                    "max_size": "",
                                    "mime_types": "",
                                    "acfe_thumbnail": 0,
                                    "acfe_validate": false,
                                    "acfe_update": false
                                },
                                {
                                    "key": "field_5d725da671042",
                                    "label": "Header",
                                    "name": "columns_row_row_card_header",
                                    "type": "text",
                                    "instructions": "",
                                    "required": 0,
                                    "conditional_logic": 0,
                                    "wrapper": {
                                        "width": "",
                                        "class": "",
                                        "id": ""
                                    },
                                    "acfe_permissions": "",
                                    "default_value": "",
                                    "placeholder": "",
                                    "prepend": "",
                                    "append": "",
                                    "maxlength": "",
                                    "acfe_validate": false,
                                    "acfe_update": false
                                },
                                {
                                    "key": "field_5d725da671043",
                                    "label": "Editor",
                                    "name": "columns_row_row_card_editor",
                                    "type": "wysiwyg",
                                    "instructions": "",
                                    "required": 0,
                                    "conditional_logic": 0,
                                    "wrapper": {
                                        "width": "",
                                        "class": "",
                                        "id": ""
                                    },
                                    "acfe_permissions": "",
                                    "default_value": "",
                                    "tabs": "all",
                                    "toolbar": "full",
                                    "media_upload": 0,
                                    "delay": 0,
                                    "acfe_validate": false,
                                    "acfe_update": false
                                },
                                {
                                    "key": "field_5d725da671044",
                                    "label": "Button (Mehr Info)",
                                    "name": "columns_row_row_card_button",
                                    "type": "link",
                                    "instructions": "",
                                    "required": 0,
                                    "conditional_logic": 0,
                                    "wrapper": {
                                        "width": "",
                                        "class": "",
                                        "id": ""
                                    },
                                    "acfe_permissions": "",
                                    "return_format": "array",
                                    "acfe_validate": false,
                                    "acfe_update": false
                                }
                            ],
                            "min": "",
                            "max": ""
                        },
                        "layout_5d6f95c598351": {
                            "key": "layout_5d6f95c598351",
                            "name": "columns_row_row_feature",
                            "label": "Feature",
                            "display": "block",
                            "sub_fields": [
                                {
                                    "key": "field_5d725da67104b",
                                    "label": "Bild",
                                    "name": "img",
                                    "type": "image",
                                    "instructions": "",
                                    "required": 0,
                                    "conditional_logic": 0,
                                    "wrapper": {
                                        "width": "",
                                        "class": "",
                                        "id": ""
                                    },
                                    "acfe_permissions": "",
                                    "return_format": "id",
                                    "preview_size": "thumbnail",
                                    "library": "all",
                                    "min_width": "",
                                    "min_height": "",
                                    "min_size": "",
                                    "max_width": "",
                                    "max_height": "",
                                    "max_size": "",
                                    "mime_types": "",
                                    "acfe_thumbnail": 0,
                                    "acfe_validate": false,
                                    "acfe_update": false
                                },
                                {
                                    "key": "field_5d725da67104c",
                                    "label": "Headline",
                                    "name": "headline",
                                    "type": "text",
                                    "instructions": "",
                                    "required": 0,
                                    "conditional_logic": 0,
                                    "wrapper": {
                                        "width": "",
                                        "class": "",
                                        "id": ""
                                    },
                                    "acfe_permissions": "",
                                    "default_value": "",
                                    "placeholder": "",
                                    "prepend": "",
                                    "append": "",
                                    "maxlength": "",
                                    "acfe_validate": false,
                                    "acfe_update": false
                                },
                                {
                                    "key": "field_5d725da67104d",
                                    "label": "Editor",
                                    "name": "editor",
                                    "type": "wysiwyg",
                                    "instructions": "",
                                    "required": 0,
                                    "conditional_logic": 0,
                                    "wrapper": {
                                        "width": "",
                                        "class": "",
                                        "id": ""
                                    },
                                    "acfe_permissions": "",
                                    "default_value": "",
                                    "tabs": "all",
                                    "toolbar": "full",
                                    "media_upload": 0,
                                    "delay": 0,
                                    "acfe_validate": false,
                                    "acfe_update": false
                                },
                                {
                                    "key": "field_5d725da67104e",
                                    "label": "Button (Mehr Info)",
                                    "name": "button",
                                    "type": "link",
                                    "instructions": "",
                                    "required": 0,
                                    "conditional_logic": 0,
                                    "wrapper": {
                                        "width": "",
                                        "class": "",
                                        "id": ""
                                    },
                                    "acfe_permissions": "",
                                    "return_format": "array",
                                    "acfe_validate": false,
                                    "acfe_update": false
                                },
                                {
                                    "key": "field_5d725da67104f",
                                    "label": "Optionen",
                                    "name": "",
                                    "type": "accordion",
                                    "instructions": "",
                                    "required": 0,
                                    "conditional_logic": 0,
                                    "wrapper": {
                                        "width": "",
                                        "class": "",
                                        "id": ""
                                    },
                                    "acfe_permissions": "",
                                    "open": 0,
                                    "multi_expand": 0,
                                    "endpoint": 0
                                },
                                {
                                    "key": "field_5d725da671050",
                                    "label": "Bild rechts",
                                    "name": "img_right",
                                    "type": "true_false",
                                    "instructions": "",
                                    "required": 0,
                                    "conditional_logic": 0,
                                    "wrapper": {
                                        "width": "",
                                        "class": "",
                                        "id": ""
                                    },
                                    "acfe_permissions": "",
                                    "message": "Bild rechts",
                                    "default_value": 0,
                                    "ui": 0,
                                    "ui_on_text": "",
                                    "ui_off_text": "",
                                    "acfe_validate": false,
                                    "acfe_update": false
                                }
                            ],
                            "min": "",
                            "max": ""
                        },
                        "layout_5d7f731463ff4": {
                            "key": "layout_5d7f731463ff4",
                            "name": "columns_row_row_b",
                            "label": "Bild (volle Breite)",
                            "display": "block",
                            "sub_fields": [
                                {
                                    "key": "field_5d7f731463ff5",
                                    "label": "Bild",
                                    "name": "img",
                                    "type": "image",
                                    "instructions": "",
                                    "required": 0,
                                    "conditional_logic": 0,
                                    "wrapper": {
                                        "width": "",
                                        "class": "",
                                        "id": ""
                                    },
                                    "return_format": "array",
                                    "preview_size": "thumbnail",
                                    "library": "all",
                                    "min_width": "",
                                    "min_height": "",
                                    "min_size": "",
                                    "max_width": "",
                                    "max_height": "",
                                    "max_size": "",
                                    "mime_types": ""
                                }
                            ],
                            "min": "",
                            "max": ""
                        },
                        "layout_5d7221914e469": {
                            "key": "layout_5d7221914e469",
                            "name": "columns_row_row_bt",
                            "label": "Bild (volle Breite) + Text",
                            "display": "block",
                            "sub_fields": [
                                {
                                    "key": "field_5d725da671057",
                                    "label": "Bild",
                                    "name": "img",
                                    "type": "image",
                                    "instructions": "",
                                    "required": 0,
                                    "conditional_logic": 0,
                                    "wrapper": {
                                        "width": "",
                                        "class": "",
                                        "id": ""
                                    },
                                    "acfe_permissions": "",
                                    "return_format": "array",
                                    "preview_size": "thumbnail",
                                    "library": "all",
                                    "min_width": "",
                                    "min_height": "",
                                    "min_size": "",
                                    "max_width": "",
                                    "max_height": "",
                                    "max_size": "",
                                    "mime_types": "",
                                    "acfe_thumbnail": 0,
                                    "acfe_validate": false,
                                    "acfe_update": false
                                },
                                {
                                    "key": "field_5d725da671058",
                                    "label": "Editor",
                                    "name": "editor",
                                    "type": "wysiwyg",
                                    "instructions": "",
                                    "required": 0,
                                    "conditional_logic": 0,
                                    "wrapper": {
                                        "width": "",
                                        "class": "",
                                        "id": ""
                                    },
                                    "acfe_permissions": "",
                                    "default_value": "",
                                    "tabs": "all",
                                    "toolbar": "full",
                                    "media_upload": 0,
                                    "delay": 0,
                                    "acfe_validate": false,
                                    "acfe_update": false
                                }
                            ],
                            "min": "",
                            "max": ""
                        },
                        "layout_5d024db252b54": {
                            "key": "layout_5d024db252b54",
                            "name": "columns_row_row_trenner",
                            "label": "Trenner",
                            "display": "block",
                            "sub_fields": [
                                {
                                    "key": "field_5d725da671059",
                                    "label": "Info",
                                    "name": "",
                                    "type": "message",
                                    "instructions": "",
                                    "required": 0,
                                    "conditional_logic": 0,
                                    "wrapper": {
                                        "width": "",
                                        "class": "",
                                        "id": ""
                                    },
                                    "acfe_permissions": "",
                                    "message": "Ein Trennelement das die Reihe mit Spalten davor beendet (erzwungener Umbruch).",
                                    "new_lines": "wpautop",
                                    "esc_html": 0
                                },
                                {
                                    "key": "field_5d725da67105a",
                                    "label": "Optionen",
                                    "name": "",
                                    "type": "accordion",
                                    "instructions": "",
                                    "required": 0,
                                    "conditional_logic": 0,
                                    "wrapper": {
                                        "width": "",
                                        "class": "",
                                        "id": ""
                                    },
                                    "acfe_permissions": "",
                                    "open": 0,
                                    "multi_expand": 0,
                                    "endpoint": 0
                                },
                                {
                                    "key": "field_5d725da67105b",
                                    "label": "Trenner Design",
                                    "name": "_inse_trenner_design",
                                    "type": "radio",
                                    "instructions": "",
                                    "required": 0,
                                    "conditional_logic": 0,
                                    "wrapper": {
                                        "width": "",
                                        "class": "",
                                        "id": ""
                                    },
                                    "acfe_permissions": "",
                                    "choices": {
                                        "stroke": "Linie",
                                        "ghost": "Unsichtbar"
                                    },
                                    "allow_null": 0,
                                    "other_choice": 0,
                                    "save_other_choice": 0,
                                    "default_value": "",
                                    "layout": "vertical",
                                    "return_format": "value",
                                    "acfe_validate": false,
                                    "acfe_update": false
                                },
                                {
                                    "key": "field_5d725da67105c",
                                    "label": "Trenner Design Optionen",
                                    "name": "_inse_trenner_design_options_1_gr",
                                    "type": "group",
                                    "instructions": "",
                                    "required": 0,
                                    "conditional_logic": [
                                        [
                                            {
                                                "field": "field_5d725da67105b",
                                                "operator": "==",
                                                "value": "stroke"
                                            }
                                        ]
                                    ],
                                    "wrapper": {
                                        "width": "",
                                        "class": "",
                                        "id": ""
                                    },
                                    "acfe_permissions": "",
                                    "layout": "block",
                                    "sub_fields": [
                                        {
                                            "key": "field_5d725da67105d",
                                            "label": "Farbe",
                                            "name": "_color",
                                            "type": "color_picker",
                                            "instructions": "",
                                            "required": 0,
                                            "conditional_logic": 0,
                                            "wrapper": {
                                                "width": "",
                                                "class": "",
                                                "id": ""
                                            },
                                            "acfe_permissions": "",
                                            "default_value": "#fff",
                                            "acfe_validate": false,
                                            "acfe_update": false
                                        },
                                        {
                                            "key": "field_5d725da67105e",
                                            "label": "Stärke",
                                            "name": "_width",
                                            "type": "number",
                                            "instructions": "",
                                            "required": 0,
                                            "conditional_logic": 0,
                                            "wrapper": {
                                                "width": "",
                                                "class": "",
                                                "id": ""
                                            },
                                            "acfe_permissions": "",
                                            "default_value": 3,
                                            "placeholder": 3,
                                            "prepend": "",
                                            "append": "Pixel",
                                            "min": 1,
                                            "max": "",
                                            "step": "",
                                            "acfe_validate": false,
                                            "acfe_update": false
                                        }
                                    ]
                                }
                            ],
                            "min": "",
                            "max": ""
                        },
                        "layout_5d70cec989566": {
                            "key": "layout_5d70cec989566",
                            "name": "columns_row_row_accordion",
                            "label": "Accordion",
                            "display": "block",
                            "sub_fields": [
                                {
                                    "key": "field_5d725da671065",
                                    "label": "Accordion Zeile",
                                    "name": "accordion_zeile",
                                    "type": "repeater",
                                    "instructions": "",
                                    "required": 0,
                                    "conditional_logic": 0,
                                    "wrapper": {
                                        "width": "",
                                        "class": "",
                                        "id": ""
                                    },
                                    "acfe_permissions": "",
                                    "collapsed": "",
                                    "min": 0,
                                    "max": 0,
                                    "layout": "block",
                                    "button_label": "Accordion Zeile hinzufügen",
                                    "sub_fields": [
                                        {
                                            "key": "field_5d725da671066",
                                            "label": "Titel",
                                            "name": "accordion_titel",
                                            "type": "text",
                                            "instructions": "",
                                            "required": 0,
                                            "conditional_logic": 0,
                                            "wrapper": {
                                                "width": "",
                                                "class": "",
                                                "id": ""
                                            },
                                            "acfe_permissions": "",
                                            "default_value": "",
                                            "placeholder": "",
                                            "prepend": "",
                                            "append": "",
                                            "maxlength": "",
                                            "acfe_validate": false,
                                            "acfe_update": false
                                        },
                                        {
                                            "key": "field_5d725da671067",
                                            "label": "Accordion Text",
                                            "name": "accordion_text",
                                            "type": "wysiwyg",
                                            "instructions": "",
                                            "required": 0,
                                            "conditional_logic": 0,
                                            "wrapper": {
                                                "width": "",
                                                "class": "",
                                                "id": ""
                                            },
                                            "acfe_permissions": "",
                                            "default_value": "",
                                            "tabs": "all",
                                            "toolbar": "basic",
                                            "media_upload": 0,
                                            "delay": 0,
                                            "acfe_validate": false,
                                            "acfe_update": false
                                        }
                                    ]
                                }
                            ],
                            "min": "",
                            "max": ""
                        },
                        "layout_5d7114e0e3584": {
                            "key": "layout_5d7114e0e3584",
                            "name": "columns_row_row_downloads",
                            "label": "Downloads",
                            "display": "block",
                            "sub_fields": [
                                {
                                    "key": "field_5d725da67106e",
                                    "label": "Downloads",
                                    "name": "_listdl",
                                    "type": "repeater",
                                    "instructions": "",
                                    "required": 0,
                                    "conditional_logic": false,
                                    "wrapper": {
                                        "width": "",
                                        "class": "",
                                        "id": ""
                                    },
                                    "acfe_permissions": "",
                                    "min": 0,
                                    "max": 0,
                                    "layout": "table",
                                    "button_label": "",
                                    "collapsed": "",
                                    "sub_fields": [
                                        {
                                            "key": "field_5d725da67106f",
                                            "label": "Download",
                                            "name": "_singledl",
                                            "type": "file",
                                            "instructions": "",
                                            "required": 0,
                                            "conditional_logic": [
                                                [
                                                    {
                                                        "field": "field_5d725da671070",
                                                        "operator": "!=",
                                                        "value": "1"
                                                    }
                                                ]
                                            ],
                                            "wrapper": {
                                                "width": "",
                                                "class": "",
                                                "id": ""
                                            },
                                            "acfe_permissions": "",
                                            "return_format": "id",
                                            "library": "all",
                                            "min_size": "",
                                            "max_size": "",
                                            "mime_types": "",
                                            "acfe_validate": false,
                                            "acfe_update": false
                                        },
                                        {
                                            "key": "field_5d725da671070",
                                            "label": "Externer Download",
                                            "name": "_singledl_extern_choice",
                                            "type": "true_false",
                                            "instructions": "",
                                            "required": 0,
                                            "conditional_logic": 0,
                                            "wrapper": {
                                                "width": "20",
                                                "class": "",
                                                "id": ""
                                            },
                                            "acfe_permissions": "",
                                            "message": "Externe Datei",
                                            "default_value": 0,
                                            "ui": 0,
                                            "ui_on_text": "",
                                            "ui_off_text": "",
                                            "acfe_validate": false,
                                            "acfe_update": false
                                        },
                                        {
                                            "key": "field_5d725da671071",
                                            "label": "Download extern",
                                            "name": "_singledl_extern",
                                            "type": "text",
                                            "instructions": "",
                                            "required": 0,
                                            "conditional_logic": [
                                                [
                                                    {
                                                        "field": "field_5d725da671070",
                                                        "operator": "==",
                                                        "value": "1"
                                                    }
                                                ]
                                            ],
                                            "wrapper": {
                                                "width": "",
                                                "class": "",
                                                "id": ""
                                            },
                                            "acfe_permissions": "",
                                            "default_value": "",
                                            "placeholder": "https:\/\/www. ...",
                                            "prepend": "",
                                            "append": "",
                                            "maxlength": "",
                                            "acfe_validate": false,
                                            "acfe_update": false
                                        }
                                    ]
                                }
                            ],
                            "min": "",
                            "max": ""
                        },
                        "layout_5d7627e37a23f": {
                            "key": "layout_5d7627e37a23f",
                            "name": "columns_row_row_video",
                            "label": "Video",
                            "display": "block",
                            "sub_fields": [
                                {
                                    "key": "field_5d7627fd7a240",
                                    "label": "Video",
                                    "name": "video",
                                    "type": "oembed",
                                    "instructions": "Geben Sie in dem Feld \"URL eingeben\" den Link zum Video ein. Beispiele:<br \/>\r\nhttps:\/\/www.youtube.com\/watch?v=jNQXAC9IVRw<br \/>\r\nhttps:\/\/vimeo.com\/channels\/staffpicks\/98741946",
                                    "required": 0,
                                    "conditional_logic": 0,
                                    "wrapper": {
                                        "width": "",
                                        "class": "",
                                        "id": ""
                                    },
                                    "width": "",
                                    "height": ""
                                }
                            ],
                            "min": "",
                            "max": ""
                        },
                        "layout_5d762bb5c8563": {
                            "key": "layout_5d762bb5c8563",
                            "name": "columns_row_row_personen",
                            "label": "Personen",
                            "display": "block",
                            "sub_fields": [
                                {
                                    "key": "field_5d762c3ac8564",
                                    "label": "Person",
                                    "name": "person",
                                    "type": "relationship",
                                    "instructions": "",
                                    "required": 0,
                                    "conditional_logic": 0,
                                    "wrapper": {
                                        "width": "",
                                        "class": "",
                                        "id": ""
                                    },
                                    "post_type": [
                                        "person"
                                    ],
                                    "taxonomy": "",
                                    "filters": [
                                        "search"
                                    ],
                                    "elements": [
                                        "featured_image"
                                    ],
                                    "min": "",
                                    "max": "",
                                    "return_format": "object"
                                },
                                {
                                    "key": "field_5d7631151dde7",
                                    "label": "Details",
                                    "name": "_ausblenden",
                                    "type": "checkbox",
                                    "instructions": "Entfernen Sie den Haken der Felder welche nicht auf der Website angezeigt werden sollen (gilt dann nur für diese Seite).",
                                    "required": 0,
                                    "conditional_logic": 0,
                                    "wrapper": {
                                        "width": "",
                                        "class": "",
                                        "id": ""
                                    },
                                    "choices": {
                                        "pos": "Position",
                                        "email": "E-Mail",
                                        "telefon": "Telefon",
                                        "address": "Adresse",
                                        "foto": "Foto"
                                    },
                                    "allow_custom": 0,
                                    "default_value": [
                                        "pos",
                                        "email",
                                        "telefon",
                                        "address",
                                        "foto"
                                    ],
                                    "layout": "horizontal",
                                    "toggle": 0,
                                    "return_format": "value",
                                    "save_custom": 0
                                }
                            ],
                            "min": "",
                            "max": ""
                        },
                        "layout_5d765d2193ab3": {
                            "key": "layout_5d765d2193ab3",
                            "name": "columns_row_row_prozentanzeige",
                            "label": "Prozentanzeige",
                            "display": "block",
                            "sub_fields": [
                                {
                                    "key": "field_5d765ef920e87",
                                    "label": "Prozent Balken",
                                    "name": "prozent_balken",
                                    "type": "repeater",
                                    "instructions": "",
                                    "required": 0,
                                    "conditional_logic": 0,
                                    "wrapper": {
                                        "width": "",
                                        "class": "",
                                        "id": ""
                                    },
                                    "collapsed": "",
                                    "min": 0,
                                    "max": 0,
                                    "layout": "table",
                                    "button_label": "",
                                    "sub_fields": [
                                        {
                                            "key": "field_5d765f1020e89",
                                            "label": "Prozent",
                                            "name": "prozent",
                                            "type": "text",
                                            "instructions": "",
                                            "required": 0,
                                            "conditional_logic": 0,
                                            "wrapper": {
                                                "width": "20",
                                                "class": "",
                                                "id": ""
                                            },
                                            "default_value": "",
                                            "placeholder": "",
                                            "prepend": "",
                                            "append": "%",
                                            "maxlength": ""
                                        },
                                        {
                                            "key": "field_5d765f0520e88",
                                            "label": "Text",
                                            "name": "text",
                                            "type": "text",
                                            "instructions": "",
                                            "required": 0,
                                            "conditional_logic": 0,
                                            "wrapper": {
                                                "width": "80",
                                                "class": "",
                                                "id": ""
                                            },
                                            "default_value": "",
                                            "placeholder": "",
                                            "prepend": "",
                                            "append": "",
                                            "maxlength": ""
                                        }
                                    ]
                                }
                            ],
                            "min": "",
                            "max": ""
                        },
                        "layout_5d766e2e96670": {
                            "key": "layout_5d766e2e96670",
                            "name": "columns_row_row_seniorenzentrum",
                            "label": "Einrichtung",
                            "display": "block",
                            "sub_fields": [
                                {
                                    "key": "field_5d766f4996671",
                                    "label": "Einrichtung",
                                    "name": "einrichtung",
                                    "type": "relationship",
                                    "instructions": "",
                                    "required": 0,
                                    "conditional_logic": 0,
                                    "wrapper": {
                                        "width": "",
                                        "class": "",
                                        "id": ""
                                    },
                                    "post_type": [
                                        "einrichtung"
                                    ],
                                    "taxonomy": "",
                                    "filters": [
                                        "search"
                                    ],
                                    "elements": [
                                        "featured_image"
                                    ],
                                    "min": "",
                                    "max": "",
                                    "return_format": "object"
                                }
                            ],
                            "min": "",
                            "max": ""
                        },
                        "layout_5d9df2c47b33a": {
                            "key": "layout_5d9df2c47b33a",
                            "name": "columns_row_row_jobsfeed",
                            "label": "Stellenangebote (Feed)",
                            "display": "block",
                            "sub_fields": [
                                {
                                    "key": "field_5d9df2dc7b33b",
                                    "label": "Info",
                                    "name": "",
                                    "type": "message",
                                    "instructions": "",
                                    "required": 0,
                                    "conditional_logic": 0,
                                    "wrapper": {
                                        "width": "",
                                        "class": "",
                                        "id": ""
                                    },
                                    "message": "Aktuelle Stellenangebote von \"<strong>https:\/\/www.awo-stellenboerse.de<\/strong>\/stellenboerse-hamburg-seniorenwohnen.json\".",
                                    "new_lines": "wpautop",
                                    "esc_html": 0
                                }
                            ],
                            "min": "",
                            "max": ""
                        }
                    },
                    "button_label": "Spalte hinzufügen",
                    "min": "",
                    "max": ""
                }
            ],
            "location": [
                [
                    {
                        "param": "post_template",
                        "operator": "==",
                        "value": "tpl-sidebar_left.php"
                    }
                ],
                [
                    {
                        "param": "post_template",
                        "operator": "==",
                        "value": "tpl-fullwidth_m.php"
                    }
                ]
            ],
            "menu_order": 0,
            "position": "normal",
            "style": "default",
            "label_placement": "top",
            "instruction_placement": "label",
            "hide_on_screen": "",
            "active": true,
            "description": ""
        }
    ]
  • “Also, when both ACF PRO and Gutenberg 6.4 are active, my ACF Block with a wysiwyg field in it does not seem to initialize the tinymce editor easily when I click into it.”

    Besides the warning message I showed in my screencast, I also get the tinymce initialization issue, BUT only when going from preview to edit mode. Clicking the “Visual” or “Text” tabs forces TinyMCE to wake up and come to life !

  • Mark, a heads up. I found this on GitHub as well for ACF. https://github.com/AdvancedCustomFields/acf/issues/218

    The guy’s screencast is what I’m experiencing.

    Also, when both ACF PRO and Gutenberg 6.4 are active, my ACF Block with a wysiwyg field in it does not seem to initialize the tinymce editor easily when I click into it.

  • @hube2

    I like where your head is at. I’m in a similar boat – not wanting to be dependent on the default wordpress editor.

    Using repeaters and flexible content I’ve created builders that allow me or my clients to build really nice looking pages and blog posts.

    In other places where I have pages/ sites that I’ve pre-built, and I want my clients to enter info like a personal photo, bio, email etc I use site options tables, and insert the info wherever necessary.

    My issue is that although I can get really nice looking results on the front end, I struggle to get my back end ACF fields to look as clean as other builders.

    Thinking forward a few more years, I think it’s really critical, for my clients at least, that the whole editing experience is more or less wysiwyg.

    When people see endless commercials for wix style editors, I don’t want my site editing experience to seem a decade behind…

    I’m trying to decide if I go all in my ACF page builder and try to make the backend editing look more like the front end results, or if I should try to build custom modules for a builder like Beaver Builder. Either using their global blocks, or possibly continuing to store everything in ACF, but exposing the data into custom beaver builder modules for “front end” editing experience… not even 100% sure that’s even possible.

    Maybe a third option is something like what mailchimp does, where you click on a preview and it loads up acf fields to edit in a sidebar. Instead of clicking “add row” in a repeater/ flexible content having a panel where users can click to select a layout. Sounds cool, but would be beyond my current abilities to develop.

    I’m curious of your perspective, and if you’ve come across any potential solutions since it doesn’t appear guttenberg will be the answer.

  • Dear all,

    After sleeping some nights over this issue, I looked again at the acf JS code and suddenly found the wysiwyg_tinymce_settings filter. This helped me to modify the input fo the tinymce.init() call. My solution is:

    
    function my_acf_input_admin_footer() {
        ?>
        <script type="text/javascript">
            acf.add_filter('wysiwyg_tinymce_settings', function( mceInit, id, $field ){
                mceInit.valid_elements = 'p,strong,em,del,span[style="text-decoration: underline;"]';
                return mceInit;
    
            });
        </script>
        <?php
    }
    
    add_action('acf/input/admin_footer', 'my_acf_input_admin_footer');
    

    This restricts the editor to only use b, i, del and underlining.

    Now I’m happy again 🙂

  • I am also now having an issue where if I move a block up or down any wysiwyg content disappears. Is this related?

  • I’m not sure I understand the question 🙂

    I think that the examples in that video are just meant to be simple to demonstrate how it work and not necessary what can be done with it.

    If I was going to build a layout for columns I would more than likely call it something like “columns” and have a radio button for selecting the number of columns to create.

    Or I might even have a repeater to allow creating whatever number of columns they wanted and maybe have settings in each column to allow the editor to choose the width of each column.

    The only time I would create a layout for a specific number of columns is if the layout needed special features that were not specific to content (wysiwyg fields) in columns.

  • I had the same problem and applied my own solution:

    new AcfTextarea();
    
    class AcfTextarea
    {
      public function __construct()
      {
        add_action('acf/render_field_settings',     [$this, 'addSettingsForWysiwyg']);
        add_filter('acf/render_field/type=wysiwyg', [$this, 'preRenderWysiwygField'], 0, 1);
      }
    
      /* ---
        Functions
      --- */
    
      public function addSettingsForWysiwyg($field)
      {
        if ($field['type'] !== 'wysiwyg') return;
    
        acf_render_field_setting($field, [
          'label' => __('Limit height of TinyMCE?', 'lang'),
          'name'  => 'wpf_tinymce_low',
          'type'  => 'true_false',
          'ui'    => 1,
        ], true);
      }
    
      public function preRenderWysiwygField($field)
      {
        if (!isset($field['wpf_tinymce_low']) || !$field['wpf_tinymce_low']) return;
    
        ob_start();
        add_filter('acf/render_field/type=wysiwyg', [$this, 'afterRenderWysiwygField'], 20, 1);
      }
    
      public function afterRenderWysiwygField($field)
      {
        remove_filter('acf/render_field/type=wysiwyg', [$this, 'afterRenderWysiwygField'], 20, 1);
    
        $output = ob_get_contents();
        $output = str_replace('height:300px;', 'height:100px;', $output);
        ob_end_clean();
        echo $output;
      }
    }
  • We’re having the same issue here, only we’re not using Gutenberg, just regular Classic Editor and WYSIWYG blocks.

    The console shows:

    TypeError: r is undefined tinymce.min.js:17183

    Any fix for this? It happens on dev and staging, although not on all sites using the same theme code / ACF Pro version.

  • It has been a long time since I’ve done this, but yes, I know that it’s possible, but you need to target the tinyMCE object of the specific field.

    I made a modification to another plugin once that was not working with multiple editors and I added this loop to the plugin. The plugin as Sortcodes Ultimate and I added this loop so that it could find the correct editor.

    
    for (i=0; i<tinyMCE.editors.length; i++) {
    	if (window.su_generator_target == tinyMCE.editors[i].id) {
    		$editor = tinyMCE.editors[i];
    	}
    }
    mce_selection = $editor.selection.getContent();
    

    But that’s the only reference I can find, it was over 2 years ago that I looked at this. Bottom line is that it is possible to manipulate the content of the editor using JS, I just don’t know if you’ll find much help doing it and I don’t know if this information will help you or not.

    You may also want to look at the ACF JS API https://www.advancedcustomfields.com/resources/javascript-api/ that has methods to get and set field values. The developer has done quite a bit of work on this and updating fields using the ACF method generally works, but I have not tried it with wysiwyg fields.

  • Hi there,

    Thanks for getting in touch!

    Please try the solutions suggested on the following thread https://support.advancedcustomfields.com/forums/topic/set-wysiwyg-height/#post-51715

    As for the gallery field feature request, please create a new ticket here: https://www.advancedcustomfields.com/contact/

    I hope this info helps.

    Thanks.

  • Validation when using the new editor does not work, other than this there are a few other minor issues when using the block editor. If you want to use the block editor then my suggestion for would be to find a way to not use required fields and make sure that the site works even if the information is not added. This is the way I code anyway and I try to do this because my clients sometimes have a hard time with “required fields”. So instead of requiring a value in a field I write my template code to check if the value is available and do different things depending on that. I hard code a “default value” that will be used if they do not enter a value. I put this information about what value will be used by default in the field’s instructions. Even if you set a field to be required it is, in my opinion, a bad idea to assume the field will have a value. What if the field is added after a post is created? That old post will not even have the field and it will not have a value. What if, somehow, that value gets deleted because of an error? Best practices when coding are to always validate all data.

    That being said, I still use ACF without issue, but then again I am not using the new block editor and I will likely never use the new block editor. It is not what my clients need or want. I do not build websites for people that want to, or should be allowed to, tweak the design of the site or its content. I build sites for companies where the design of every element is predetermined and fixed so that every page has a consistent look. 99.9% of my clients do not want to worry about or learn how to deal with content layout, they simply want to add content. I install classic editor on the site and then, beleive it or not, I do not use that either. I use nothing but ACF fields and I use an ACF WYSIWYG editor to replace the classic editor.

  • Flexible content is what I use, I was just trying to answer based on adding field to “the content”. You are not the only one that is not happy with the direction of WP and guberbug. I use flexible content to give clients the ability to add “sections” of a page in any order they want, or even to add the same layout multiple times. It may not seem like a page builder, but it is. You’re just not using a monolithic page builder. We design the admin and the flex fields to meet the specific needs of each client so that they can just “add content” without needing to, or being allowed to, alter the design of a page or even a page element, at least not beyond the controls that we give them.

    Even where we are not doing this we are now replacing the standard WP editor with an ACF WYSIWYG field. This way we do not use the block editor at all and we are not dependent on the classic editor either since it’s future support is not likely.

    ACF does have it’s one shortcode, it’s extremely simple and it only works with simple text based fields. It’s not something you can use in the way you’re looking for https://www.advancedcustomfields.com/resources/shortcode/

  • Found this Help item, but it doesn’t work. Nothing happens. Is there a way to call my_toolbars in a specific custom field group?

    https://www.advancedcustomfields.com/resources/customize-the-wysiwyg-toolbars/

    Thanks!

  • After doing more digging it seems that there’s nothing built into the api for this. So instead I had to write a bunch of code to take care of it. It’s just a start, and might not work for some field configurations (like cases where an image field returns just an id instead of an object), I’m not sure I’d paste this straight into production, but it’s a decent starting point. At the very least it could use a refactor to not be a single big, ugly function.

    
    function setFieldValue(field, value) {
        switch (field.data.type) {
            case 'repeater':
                //Clean out any row there by default
                var rows = field.$rows();
                if (rows.length > 0) {
                    field.remove(field.$rows().eq(0));
                }
    
                for (var rowIndex in value) {
                    var row = value[rowIndex];
                    var rowEl = field.add();
    
                    for (var rowName in row) {
                        var rowVal = row[rowName];
                        var repeaterSubField = acf.getField(rowEl.find('[data-name="' + rowName + '"]'));
    
                        setFieldValue(repeaterSubField, rowVal);
                    }
                }
    
                break;
    
            case 'clone':
                for (var cloneKey in value) {
                    var cloneValue = value[cloneKey];
                    var cloneSubField = acf.getField(field.$el.find('[data-name="' + cloneKey + '"]'));
    
                    setFieldValue(cloneSubField, cloneValue);
                }
                break;
    
            case 'image':
            case 'file':
                var atts = {};
                for (var k in value) {
                    atts[k] = value[k];
                }
                value.attributes = atts;
                field.render(value);
                break;
    
            case 'wysiwyg':
                var $wrap = field.$control();
                if ($wrap.hasClass('delay')) {
                    $wrap.removeClass('delay');
                    $wrap.find('.acf-editor-toolbar').remove();
                    field.initializeEditor();
                }
    
                var editorWrap = field.$el.find('.wp-editor-wrap');
                if (editorWrap.length > 0) {
                    var editorID = editorWrap.eq(0).attr('id').replace(/^wp-/, '').replace(/-wrap$/, '')
                    window.tinyMCE.get(editorID).setContent(value);
                }
    
                break;
    
            case 'oembed':
                var url = $(value).attr('src').split('?').shift();
    
                field.$search().val(url);
                field.val(url);
                field.$el.find('.canvas-media').html(value);
    
                break;
    
            case 'gallery':
                for (var attIndex in value) {
                    var att = value[attIndex];
                    field.appendAttachment(att, attIndex);
                }
    
                break;
    
            case 'checkbox':
                field.$inputs().each(function (i, checkbox) {
                    if (value.indexOf(checkbox.value) >= 0) {
                        checkbox.setAttribute('checked', 'checked');
                    }
                });
                break;
    
            case 'radio':
                field.$control().find('[value="' + value + '"]').prop('checked', 'checked');
                break;
    
            case 'button_group':
                field.val(value);
                field.$el.find('input[value="' + value + '"]').prop('checked', 'checked').trigger('click');
                break;
    
            case 'true_false':
                if (value) {
                    field.$input().prop('checked', 'checked');
                }
                break;
    
            case 'post_object':
                setSelect2FieldValue(field, value.ID, value.post_title);
                break;
    
            case 'page_link':
                setSelect2FieldValue(field, value, value);
                break;
    
            case 'relationship':
                var loadCheck = setInterval(function () {
                    if (!field.get('loading')) {
                        clearInterval(loadCheck);
                        for (var relIndex in value) {
                            var post = value[relIndex];
                            field.$el.find('[data-id=' + post.ID + ']').trigger('click');
                        }
                    }
                }, 100);
    
                break;
    
            case 'taxonomy':
                for (var taxIndex in value) {
                    field.$el
                        .find('[value=' + value[taxIndex] + ']')
                        .prop('checked', 'checked');
                }
                break;
    
            case 'user':
                var userLabel = value.user_nicename + ' (' + value.nickname + ')';
                setSelect2FieldValue(field, value.ID, userLabel);
                break;
    
            case 'google_map':
                break;
    
            case 'date_picker':
            case 'date_time_picker':
            case 'time_picker':
                field.val(value);
                field.$el.find('[type=text]').val(value);
                break;
    
            default:
                field.val(value);
        }
    }
    
  • Going to be honest with you, I have no idea. I have made the decision that I will not be using the block editor for the foreseeable future. Frankly, it’s not what my clients want or need for various reasons. I am working towards not allowing the default editor and new themes that I’m building are replacing the default WP editor with an ACF WYSIWYG field in all cases. Having made this decision I have not even looked at ACF blocks. It also means that I may need to pull one of my plugins off of the WP repo.

  • The goal of gubergug is to allow the client to edit the entire page, eventually. Managing these sections all through the block editor. Trust me, I understand this, my clients need structure and none of them should be allowed to tweak the design of a page. Moving forward I am completely removing dependency on the default WP editor and will be using nothing but ACF fields for all content, including the main content. Either ACF will continue to support tinyMCE for it’s WYSIWYG or someone, maybe me, will build a custom field type for it if it’s removed, although I doubt it will be removed. I am not the only person in the world going in this direction.

  • You’ve already answered you own question. No, you cannot put blocks in an ACF WYSIWYG field.

    I don’t even understand why anyone would want to do this.

  • That’s unfortunate that inner blocks isn’t supported yet. Like you, I had to settle for WYSIWYG editors inside my columns.

    For my column layout I went with a repeater and styled it for a horizontal layout. I widened the content area so there is more room to work inside each column. I also added a button group for different column layouts. For example there are 4 layouts for 3 columns, 5 for a 4 column layout, etc. Then I used JS to resize the column widths based on which layout was selected.

    Overall it works nicely.

  • That’s unfortunate inner-blocks isn’t supported yet. Like you, in the meantime I had to settle for using WYSIWYG editors inside of my columns.

    For my column layout, I went with a repeater and styled them to be horizontal. I widened the content area so there is more room to work inside each column, it works out pretty good. I also added a button group for different column layouts and then use JS to automatically resize the column widths based on the layout selected.

    Overall I guess I am happy with it.

    column layout

  • Elliot is going to look into inner-blocks later on this year, my guess is Nov/Dec… In the meantime what I have done to create my own columns, have each column in Accordion fields, and for the content of the columns use the WYSIWYG editor. I can get away with it, becaus so far all of my 41 blocks, are conversions from my preexisting shortcodes. And because TinyMCE displays the button to generate the shortcodes, it works pretty well. Also because I’m using accordions, I’m actually building the columns vertically, which give me more room to edit things. The biggest drawback is that if I want to change the layout (ie: from 3 columns to 4 columnjs), I have to delete the 3 column block and start a new 4 column block…

  • Hi John,

    Thanks. I appreciate the basic info, though perhaps I have understated my experience level. I’m more an intermediate-level coder with respect to both WordPress and PHP; I understand the basics of both, but still have to look up a lot of things like filters and actions or PHP functions and precise parameters as I more often than not need a refresher.

    So, I definitely do know which template I’m using for the page in question already. I can tell in the page editor, and it’s a template I wrote the PHP file for myself. Other fields and custom fields are working fine, including not only the built-in WYSIWYG editor but 3 other ACF fields. Only the ACF WYSIWYG field is not displaying anything.

    I’ve also tried echoing the problematic ACF field both inside and out of the loop, to no avail.

    Maybe a code snippet would be helpful. Here’s my template PHP file’s contents (page-feature.php). The $subtext variable (get_field(“additional_subtext”)) is the problematic field; the other three fields all work fine ($heading and $button_text are ACF Text fields, $btnLink is an ACF Link field).

    <?php
    /**
     * Elegant Simplicity Theme: Feature Page Template
     *
     * This template is...
     *
     * Template Name: Feature Page
     *
     * @link https://developer.wordpress.org/themes/basics/template-hierarchy/
     *
     * @package Elegant_Simplicity
     * @since 5.2.0
     */
    
            get_header();
    
            $heading = get_field("heading");
            $btnText = get_field("button_text");
            $btnLink = get_field("featured_link");
            $subtext = get_field("additional_subtext");
    ?>
            <h1 class="cover-heading"><?php echo $heading; ?></h1>
    <?php   while (have_posts())
              {
              the_post();
              get_template_part('template-parts/content-featurepost', 'page');
              }
    ?>      <p class="lead"><a href="<?php echo $btnLink; ?>" class="btn btn-lg btn-outline-secondary"><?php echo $btnText; ?></a></p>
    <?php   if (!isset($subtext) || '' === trim($subtext))
              {
              echo $subtext;
              }
    
            get_footer();
    ?>

    Thanks!

  • Hi, i got the same problem.
    no matter which acf field i use (textarea or wysiwyg editor) in the field group, all the postet html tags (for example an iframe) gets deleted when i save the page.
    that’s only happening on my server setup not on my localhost.

    can you tell me what i need to change on my server?

Viewing 25 results - 351 through 375 (of 1,294 total)