How i can create a welcome message area for my frontpage with backend control {admin panel}



  • Are you able to modify your template files, or are you looking for a plug and play solution? – Pippin Jun 24 '12 at 14:36
  • 1
    Please improve your question: Where and how do want to add that content: editing the theme, installing a plugin? Show us your research efforts. – fuxia Jun 24 '12 at 16:39
  • Dear Toscho i want to edit the theme not plugin , i do research !! . i need to make it option using theme option – Rasha Nour Eldin Jun 25 '12 at 9:16
  • dear pippin as i answered i need to edit the theme – Rasha Nour Eldin Jun 25 '12 at 9:16

Create a page theme, then call it in index.php:

$recent = new WP_Query( 'page_id=**ID**' ); 
while ( $recent->have_posts() ) : $recent->the_post();
    ?><h3><?php the_title(); ?></h3><?php 
  • <?php $recent = new WP_Query("page_id=**ID**"); while($recent->have_posts()) : $recent->the_post();?> <h3><?php the_title(); ?></h3> <?php the_content(); ?> <?php endwhile; ?> – ahmedag Jun 24 '12 at 12:25
  • 2
    You can edit your own answer to make corrections and updates... Also, use the proper formatting for code. – brasofilo Jun 24 '12 at 14:10

Put a loop on the front page limited to posts with the tag "welcomeMessage". Then, on the back end write a post with that tag. Edit the post whenever you want to change the message.


If you are using a static frontpage, you can add the message to a custom field on the post editing screen and then put a shortcode in the page to display it, e.g. [welcome-message].

add_shortcode( 'welcome-message', 'echo_welcome_message' );
function echo_welcome_message() {
    global $post; 
    return get_post_meta( $post->ID, 'welcomemessage', true );

I don't see how this is really much different than just adding the welcome message to the top of the page content, but hope it helps.

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.