0

I would like to have my authors to be able to create new pages on my site, but I would like a couple of shortcodes to automatically be included when they create each page. The shortcodes independently work with pages already with no adjustments or editing. How can I have this done automatically?

0

You can add any default content you like, but I don't know of a way of doing it just for Pages (the following will apply to both Pages and Posts):

add_filter( 'default_content', 'my_default_post_content' );

function my_default_post_content( $content ) {
    $content = "Hello World!";
    return $content;
}

(place this in your functions.php file)

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.