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 trial

WordPress

Nikko Ong
Nikko Ong
2,035 Points

[Bootstrap one page theme] Is it possible to have multiple pages in one template?

Hi, newbie here.

I'm wondering how to implement multiple pages in a one page theme. Also, is there a way where you can put # (hash) in pages links?. I already tried putting # in the pages links and it seems that WordPress doesn't accept it.

Basically, I want to create a CMS for a one page theme template that has a link where if the guest/visitor clicks the link it will scroll to that section.

Thanks :D

5 Answers

Nikko Ong
Nikko Ong
2,035 Points

Thanks! I'll try this out :D

Derek Crosson
Derek Crosson
991 Points

I think the correct way to do this would be to use a template page and create custom post types. A "dirtier" way that I prefer using is to put the necessary code in the front-page.php file and create dynamic sidebar widgets in the functions.php file then call them in the front-pafe.php file.

Nikko Ong
Nikko Ong
2,035 Points

Thank you for your answer, I also notice under appearance > menu that there is a custom links tab where you can add a custom menu and specify your desired link. You can also specify # links there rather than creating post types based on my understanding then display the custom links on the page and create dynamic sidebar widgets for the sections. But I think this is also a dirty way. Anyway, I'll try both. thanks again :)

jason chan
jason chan
31,009 Points

yes it's called angular js or emberjs. These javascript frameworks allow a single page to dynamic.

jason chan
jason chan
31,009 Points

I think zac has bootstrap course here.

Nikko Ong
Nikko Ong
2,035 Points

Yes, I'm still browsing all the tutorials and gonna try it out. Thanks! :D

Nikko Ong
Nikko Ong
2,035 Points

Thanks, I'm already done with this tutorial and it really helped me add a theme to my WordPress.