Custom Fields
Support General How to output a shortcode?

  • Creator
  • #27222
    Resolved Kara

    Hi there - I'm starting a new thread since other was marked as solved without detailing how.

    I need to add a shortcode to a CPT in the backend using a custom field that will then show on the front end. Is this possible?

Viewing 3 replies - 1 through 3 (of 3 total)
  • Author
  • #27226
    Long Nguyen


    Thank you for reaching out.

    Please follow this documentation to know how to use the shortcode [ rwmb_meta ]


    Hi Long - thanks for your quick response.

    Let me clarify - I don't want to create a shortcode of the Meta Box custom field, I need to add an existing shortcode from another plugin (in this case to show a registration form on the front end).

    Here's my workflow:
    Create CPT > Add custom field for shortcode > copy/paste registration form shortcode into custom field > registration form is visible on the front end.

    If it matters, I'll be using Elementor to pull the custom fields to a template for the CPT.

    Maybe there is a function I can add to my theme file to let me add shortcodes to the custom HTML field?

    Long Nguyen


    Thank you for your additional information.

    If you want to insert a shortcode from another plugin, you can just use the widget Shortcode of Elementor to insert it, no need to insert via a custom field.

    Or you can insert a shortcode via the field type WYSIWYG

Viewing 3 replies - 1 through 3 (of 3 total)
  • You must be logged in to reply to this topic.