I think this is what you’re looking for…
function wpa_content_filter( $content ) {
global $post;
if( $meta = get_post_meta( $post->ID, 'demo_link', true ) ) {
return $content.' <a href="'.$meta.'">'.$meta.'</a>';
}
return $content;
}
add_filter( 'the_content', 'wpa_content_filter', 10 );
Related Posts:
- Individual Widgets per Page
- ‘Preview Changes’ for custom meta boxes?
- Using TinyMce with textareas in meta boxes on custom post types
- add meta box – custom field : which to choose?
- Add metabox to document tab in gutenberg
- How to add add_meta_box to specific Page Template?
- How can I avoid re-inventing the Custom Fields wheel in my Plugin’s Metabox?
- Add custom option to Standard Page Attributes Meta Box
- Only show metabox when date-value in other metabox is over?
- Populating meta box with select-list of existing posts, and assigning it to custom post types
- Create meta boxes that don’t show in custom fields
- How To Create a Metabox of HTML Content with Instructions For Editors When Editing a Post or Page?
- TinyMCE in Custom Metabox not loaded after upgrading from WP 3.1.4 to WP 3.2
- wp_editor in add_meta_boxes does not show gallery
- How do I assign this filter to a variable? (Appending php & markup to the_content)
- Problem with adding exta field in metabox in custom post type
- Adding a custom field or metabox to the post-thumbnail widget?
- How do I add custom_meta_box_id’s value?
- Metabox image upload and custom field
- all tincymce’s switch when updating page after changing from html to text in custom metabox
- My metabox class
- How to construct multiple meta boxes
- Loading scripts to the Post Edit page only
- Force hide custom field metaboxes
- Woocommerce with metabox plugin
- How to Display Custom Meta Box only on Specific Page IDs
- Metabox will not save
- How to check for specific meta box value on front end and output accordingly
- How Meta Data is different from Custom Fields of POST/PAGE in WordPress
- Tweak Meta for Post to work it for Pages also
- custom field not saved
- How to create a Custom Meta Box with Name/Value Admin User Input Fields?
- Create Multiple File Upload Metabox in WordPress
- Users Select inside custom metabox
- Custom Metabox Not Saving
- Better Method for Multiple Meta Boxes
- Should custom meta boxes be able to output shortcodes the same as WordPress’ native post editor?
- Unsaved changes in metabox inputs not detected in the block editor
- Custom Meta Box (SELECT) Not Saving
- Get updated meta value after post update or published (custom post type) using hook
- Button inside Custom Meta Box triggering the Update Button
- Why is my Custom Meta Box Field Inputs NOT saving?
- custom-meta-box checkboxes from loop won’t save
- I need a “Choose from existing content” popin
- Outputing a metabox textarea and avoid line breaks inside li tags
- How can you include custom post meta in search without calling each key?
- shortcode in a custom metabox
- Specific coditional usage [closed]
- Problem with saving large amount of data in postmeta/usermeta
- Move Title and the Content WYSIWYG editor position
- How can I hide custom field from users used for caching response from external api?
- How to use media upload on metabox post page without breaking TinyMCE?
- Displaying Meta-Box Data Properly
- Let’s Create Custom Field Template Documentation
- Can I save post meta programatically without setting metaboxes?
- Meta box values are displayed on Custom Fields list. Is it possible to hide them?
- If metabox has content display content
- Custom meta boxes not saving
- HM CMB: Role Select
- Get meta field value of all catgories
- How to store meta field values
- How to Convert Custom Fields from Text to Array?
- Make separate text boxes for separate WordPress Custom Fields
- show a specific metabox dependent on the page template
- Making custom meta box required (with error message if not filled in) on Gutenberg
- Set class if a meta value is set within post archive
- WordPress Blocks, setAttributes not saving
- Using Customizer API vs Custom Meta Box for custom content
- non-unique #_ajax_nonce id in browser console
- How can I ‘check’ the “custom fields” box from the Screen Options?
- Allow HTML in Custom Metabox area
- Metabox/Custom fields are not saving input data
- Custom field metabox not showing in back-end
- Issue on Creating Checkbox Field On Custom Post type
- WordPress admin area: select box with 12.000+ options
- How to display selected option from dropdown list in a metabox
- Save, update, get and sanitize post meta as HTML not plain
- Why does this javascript search function in the WordPress Admin not work?
- Create Meta boxes dynamically
- Update custom table on metabox POST
- Save input form on custom field
- Metabox value for post loop?
- how to modify a field’s size in a metabox : ROWS height, and scroll control?
- Append custom field items to content from plugin
- Get meta value when the page is a blog archive
- When post is updated, custom metadata in text area field is overwritten
- Custom Meta Boxes and Fields for WordPress: Change directory upload based on user-edit page
- wp_postmeta are updated for only one page
- Meta Box Data added to header redirect
- Can i categorise my meta box?
- Custom metaboxes not saving after switching themes
- Custom Metaboxes, multiple post selection
- added a meta box to post however when saving menu while debug on throws a warning
- When editing a post with a custom meta box the values aren’t displaying correctly
- Use Metabox to enter Post Title
- Include custom fields into the content of a regular page
- Get fields from metabox array
- How to get the value of particular get $meta value in wordpress
- How to add new Metadata options (Date, Author, etc.) for Posts?
- Saving multiple custom meta box fields