Welcome to the Treehouse Community
Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.
Looking to learn something new?
Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.
Start your free trialJeremy Coleman
5,449 PointsHow would I include just a portion of html using the include statement?
I am building a website (don't have the code yet). I am planning on building a website/blog.
What I want to do is, when I update the blog, I want the newest blog post to be on the front page.
More clearly, I'll have a landing page with a tagline, under it will be the latest blog post on the website. I know how to include files using
<?php include 'menu.php';?>
but how would I go about using just a portion? I am fairly new to php, thank you in advance.