You have used the same quotation characters in 2 different contexts. You should write the shortcode in the following way:
[example text="<a href="http://example.com">lorem</a> ipsum"]Lets roll[/example]
Then, “unescape” HTML entities on the shortcode output:
$return_string = '<div class="some-class">'. html_entity_decode($text) . $content .'</div>';
Related Posts:
- Solution to render Shortcodes in Admin Editor
- Include PHP file in Content using [shortcode]
- Shortcode producing headers already sent error
- Enabling shortcodes for custom fields
- How to use get_media_embedded_in_content function
- Shortcode with parameters inside parameters
- Changing a function in function.php to a shortcode – for listing categories of only a certain post type
- how to create shortcode in wordpress
- What is wrong with this Shortcode? I get it in a wrong place inside the content
- Display random text from a file with the WP built-in AJAX API
- Set first oembed in post to a global variable or function
- Formatting post content to exclude gallery
- Remove images from get_the_excerpt
- Problem with extract() with custom shortcode
- Using locate-template & shortcodes doesn’t appear to work
- Displaying a random user with a shortcode
- Adding body class when post contains a specific shortcode
- creating shortcode to pull json array
- Pass Shortcode Attribute to footer Script
- Detect Safari desktop browser and include the detection in a shortcode
- My simple custom shortcode is not longer working (possibly due to upgrade to WordPress 4.4 ?)
- List child pages of specific page using shortcode
- Display first name of logged in user?
- WordPress shortcode attributes for database SELECT?
- create shortcode to list users with specific meta key value
- Variable if post is sticky in functions.php
- Having issues with a foreach inside of a shortcode with ACF gallery
- Shortcode inserts paragraphs before and after executing shortcode
- How can I make a widget shortcode to control all the widgets?
- Custom shortcodes not inserting into visual composer columns
- Create a custom taxonomy that will be used to create and filter markers in a Google Map
- Setting youtube size in functions.php
- Adding a colorbutton in tinymce dialog with current api
- Passing variable as add_shortcode argument
- Add button to kitchen sink toggle
- Optimizing a WordPress site
- Help With Creating Shortcode
- Shotcode argument issues
- Shortcode parse error – wrong syntax
- Exclude category from shortcode
- wp_nonce_field is breaking form for reasons unknown
- Adding an option to a shortcode
- Testing for a shortcode using a function. 404 page throwing PHP Notice
- Echoing function into WordPress NextGen gallery
- Output loop to function return?
- How to parse a shortcode within a shortcode?
- Variables not showing in short code
- Woocommerce checkout field
- How to include any template using Shortcode fuction?
- How can I pass a shortcode value to the head in wordpress functions.php
- Native gallery custom html output
- Need to convert image url to a Base_64 data url with wordpress function..
- dynamic site link for future migration in echo do_shortcode()
- Need a method to prevent WP from adding in between my shortcodes
- Load scripts for do_shortcode( ‘ [ my_shortcode ] ‘ )
- Shortcode question
- How to create a shortcode out of a php function
- Modify shortcode to work with custom post types
- shorthand syntax for custom fields
- Shortcode of a function
- show all the posts thumbnails
- How to add a shortcode to call a function
- How can I call a PHP function inside a hardcoded shortcode?
- Using One Function To Create Two Different Shortcodes
- Is it possible to create a shortcode to link to a specific post/page where the tag is just an attribute?
- Load templates, pass arguments, and render output from functions.php
- How to add if statement on WordPress shortcode output
- Passing function arguments via a shortcode
- Pagination not working – FrontPage
- Customizing the wp_video_shortcode output with add_filter
- page shows short code not output
- Probleme shortcode with list author
- Function to function shortcode help [closed]
- I want to display the sku in the product pages of my EDD website
- Shortcode to output category description by passing ID
- Help using ShortCodes to style whole chunks of the post
- Shortcode to insert default text and change one word throughout it?
- use add_action in a shortcode (gravity form – WordPress)
- Shortcode displaying outside the div [duplicate]
- Shortcode Initialization in a Custom Theme
- Shortcode with pagination advancing multiple queries
- Show users last read posts for each user?
- Get shortcode attribute value to another function
- Hide disclaimer from summary excerpts
- Function not receiving string from shortcode
- How To Show Shortcodes In WordPress Custom Fields?
- Shortcode to eliminate and replace with
- Problem in outputting shortcode
- Problem in shortcode outputting content
- Pull random comment from specific post, display on homepage with shortcode
- Set thumbnail from URL, by grabbing image in functions.php
- Shortcode to output get_header not working
- using enqueue_script in a shortcode isn’t working
- Gallery Shortcode Function Help
- Echo custom field value in shortcode function
- Shortcodes not outputting in correct divs
- trouble with passing class method data to outside function
- Get term count on a category page
- How do grab the main loop, with conditions, and output via shortcodes
- PHP error in shortcode [closed]