Answers for "wordpress shortcode with parameters"

PHP
1

add shortcode in wordpress

// function that runs when shortcode is called
function wpb_demo_shortcode() { 
 
// Things that you want to do. 
$message = 'Hello world!'; 
 
// Output needs to be return
return $message;
} 
// register shortcode
add_shortcode('greeting', 'wpb_demo_shortcode');
Posted by: Guest on March-18-2020
0

php shortcode wordpress return content with shortcodes

return do_shortcode($content);
Posted by: Guest on September-30-2020

Code answers related to "wordpress shortcode with parameters"

Browse Popular Code Answers by Language