This should work assuming your trying to pass the URL to the PDF short code
$file= get_post_meta( $post->ID, 'teacher-resume-upload' );
if ( $file) {
foreach ( $file as $attachment_id ) {
$full_size = wp_get_attachment_url( $attachment_id );
echo do_shortcode( '[pdf]' . $full_size . '[/pdf]' );
}
}
Related Posts:
- Audio or playlist shortcode condition according to the amount of files on attachment page
- shortcode get thumbnail size
- Use full size images in a specific gallery
- Auto embeds don’t work for attachment descriptions
- How to include shortcodes and pdfs in WordPress search without plugin?
- Using get_option() in JavaScript
- Shortcode empty attribute
- Making a Shortcode [NEXT] and [PREVIOUS] to place into specific posts for post navigation
- How to display the site name in a WordPress page, or post
- How can I put a wp_redirect into a shortcode?
- Native “playlist” shortcode random playing… How?
- Stop strip_shortcodes() stripping content inside shortcodes
- Using audio shortcode for .mp3 URLs with a query string
- Get multiple shortcode attribute values
- How do i link gallery thumbnails to different url’s using the wp native gallery?
- Why do_shortcode is not executing the shortcode in data-* html attributes?
- How to save a shortcode in a Gutenberg custom block?
- Is shortcode_unautop() broken?
- Some doubts about gallery shortcode in WordPress
- has_shortcode for content added after the content
- Can a shortcode function this way
- Dynamically create shortcodes using add_shortcode and a callback
- Creating a Slider Shortcode Based on Nivo Slider
- How can I make a shortcode from this code?
- Meta tags in shortcode
- Adding PHP/HTML code inside page from custom template
- WordPress auto adds p to shortcode parameters
- Why isn’t this youtube shortcode working?
- Gist shortcode is not working
- ShortCode and extra
- How to change page title (from a plugin) in twentytwentyone theme
- WordPress Code Standards and Working $link Parameters In Shortcode
- How to set Contact Form 7 fields default value using shortcode attribute? [closed]
- Shortcodes Keep Wrapping in
- If you add a shortcode programmatically, but the code isn’t viewed on that request, is it still executed?
- Problem with using custom shortcode with ACF WYSIWYG field
- How can I escape a section of my page which contains multiple shortcodes?
- Populate shortcodes with table data and get next row
- Running shortcode with variable that is modified
- shortcode to display post by category entered by user without plugin
- Shortcode is not processed when added to option field using wp_editor
- How to apply an ID to Shortcode Embedded iframe
- Adding Shortcode Values to wp_head
- How to change the output of gallery shortcode
- wp_list_pages shortcode jumps above previous content
- Shortcode attributes don’t appear?
- Retrieving post excerpt as a shortcode
- Using $this from child class inside shortcode function
- Div-Wrap with Functions.php in Childtheme using Shortcode!
- What is the correct syntax to append a URL using a shortcode for an iframe?
- Shortcodes in RSS excerpts
- How to trace shortcode to its functionality
- shortcode issue in the_excerpt
- If else with shortcodes
- Using shortcodes to communicate my page design
- How to check if a post has any one of many shortcodes?
- Use Contact Form 7 with Ajax
- Is it possible to add a shortcode’s content to a table?
- call other shortcode in the email contactform7 send [closed]
- Putting a space between the buttons [closed]
- Dynamic number within shortcode
- How can i strip shortcode from HTML title tag?
- Need help with creating a simple shortcode
- Returning HTML to Shortcode Block
- WP REST API remove the WordPress shortcodes from the JSON wp/v2/posts content->rendered
- How to display html element and php string in the same line?
- i want to show a modal when user lands on home page very first time
- Hide download option video shortcode
- WordPress Shorcode Display hierarchical taxonomy [child, parent]
- Shortcode not working in Jetpack Top Posts & Pages widget
- Restricting shortcode for users
- Attach and retrive multiple pdf files to post or page
- Gutenberg running code only available in front end within shortcode
- Insert HTML in content property and render it using shortcodes
- Redirect per shortcode if user is logged in
- Shortcode, vs blocks, vs templates – what would you do for choosing or creating custom post data in editor?
- Logout user if click on a custom page link
- Shortcode Attribute not defined
- Convert WordPress shortcodes into plain html
- Attributes are not passed on nested shortcode
- Second attribute of shortcode is not changing why?
- How to make a shortcode with a line break in it parse correctly?
- Load next post by ID on a single page
- Plugin Shortcode value in post
- Woocommerce Filter Main Loop by Tag [closed]
- Shortcodes: override a shortcode / change shortcode on the fly
- Access the resized images generated by `add_image_size()`
- Separating Custom Template logic
- Remove width and height attributes from [gallery] output
- woocommerce Product shortcode create [closed]
- A number appears inside a div called wpb_wrapper, when I use a custom shortcode
- Enclose article’s body with default shortcode
- Help with Shortcode Functionality
- Shortcode Site include in a other
- Why is my ajax live search not working when i use a shortcode to call it?
- Shortcode with foreach
- How do write this type shortcode? [closed]
- WordPress functions.php shortcode is not working [closed]
- My first WordPress shortcode just returning []
- WordPress shortcode select option not working [closed]