Home>Support>custom field

custom field

Good day. I registered a custom field, here is the code how I did it.

code

Now I need to display this data inside the widget in which the data is filled.
With the help of which Actions can I bind to display what content at the very beginning of the widget?
I need to display my content in the widget markup, after the first wrapper.

This is our free support forum. Replies can take several days. If you need fast email support, please purchase a SiteOrigin Premium license.

  1. 1 month, 11 days ago Andrew Misplon
    Hi, I Work Here

    Hi Сергей

    To display your custom field data just after the first wrapper in your widget’s markup, try using the 'siteorigin_widgets_template_variables_' . $this->id_base filter to add your custom field to the template variables, then update your widget’s template (e.g., tpl/default.php) to show the data after the opening wrapper, like

    <div class="widget-wrapper">

    For details, see the Template Variables Filter documentation.

    Thanks

    Andrew

Please log in to post on our forums. Signing up is free.

Get The Most Out of SiteOrigin with SiteOrigin Premium

Find Out More