• Skip to main content
  • Skip to forum navigation

StudioPress

  • Shop for Themes
  • My StudioPress

Forum navigation

  • Home
  • General Genesis Discussions
  • StudioPress Themes
  • Genesis Blocks
    • Genesis Blocks
    • Genesis Custom Blocks
  • Retired Themes
  • FAQs
  • Forum Rules
  • Internationalization and Translations
  • Forum Bugs and Suggestions
  • Forum Log In

Are You Using The WordPress Block Editor?

Genesis now offers plugins that help you build better sites faster with the WordPress block editor (Gutenberg). Try the feature-rich free versions of each plugin for yourself!

Genesis Blocks Genesis Custom Blocks

Where to write code in page template – agency theme

Welcome!

These forums are for general discussion on WordPress and Genesis. Official support for StudioPress themes is offered exclusively at My StudioPress. Responses in this forum are not guaranteed. Please note that this forum will require a new username, separate from the one used for My.StudioPress.

Log In
Register Lost Password

Community Forums › Forums › Archived Forums › General Discussion › Where to write code in page template – agency theme

This topic is: resolved

Tagged: Agency, code, page, template

  • This topic has 1 reply, 2 voices, and was last updated 12 years, 2 months ago by nutsandbolts.
Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • October 4, 2013 at 3:15 am #65328
    Bart
    Member

    I have been trying to add extra code in my page template, but no matter where I put it, it messes up the design of the page,
    The page becomes just white with the standard genesis code written out and then the post or page, without any layout.

    For example, I want to display featured pages in a specific page. So a list of pages with their image and an exerpt. I have found this piece of code on another forum:

    <?php
    $post_id = 1;
    $queried_post = get_post($post_id);
    $title = $queried_post->post_title;
    echo get_the_post_thumbnail($post_id);
    echo "<h2>" . $title . "</h2>";
    echo "<p>" . $queried_post->post_excerpt . "</p>";
    ?>

    But I just can't figure out in which position to paste it in my Genesis Page Template in order for it to properly function.

    November 25, 2013 at 2:00 am #75461
    nutsandbolts
    Member

    I see this is marked as resolved but just wanted to check to make sure you didn't check it by accident. Let us know if you still need help!


    Andrea Whitmer, Owner/Developer, Nuts and Bolts Media
    I provide development and training services for designers • Find me on Twitter and Google+

  • Author
    Posts
Viewing 2 posts - 1 through 2 (of 2 total)
  • The forum ‘General Discussion’ is closed to new topics and replies.

CTA

Ready to get started? Create a site or shop for themes.

Create a site with WP EngineShop for Themes

Footer

StudioPress

© 2026 WPEngine, Inc.

Products
  • Create a Site with WP Engine
  • Shop for Themes
  • Theme Features
  • Get Started
  • Showcase
Company
  • Brand Assets
  • Terms of Service
  • Accptable Usse Policy
  • Privacy Policy
  • Refund Policy
  • Contact Us
Community
  • Find Developers
  • Forums
  • Facebook Group
  • #GenesisWP
  • Showcase
Resources
  • StudioPress Blog
  • Help & Documentation
  • FAQs
  • Code Snippets
  • Affiliates
Connect
  • StudioPress Live
  • StudioPress FM
  • Facebook
  • Twitter
  • Dribbble