function fuctionname() { $arg = array( 'post_type' => 'posttype', 'posts_per_page' => -1 ?> <div></div> <?php wp_reset_postdata(); } add_shortcode('short-code-name', 'fuctionname');
Preview:
downloadDownload PNG
downloadDownload JPEG
downloadDownload SVG
Tip: You can change the style, width & colours of the snippet with the inspect tool before clicking Download!
Click to optimize width for Twitter