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

PHP Object-Oriented PHP Basics Building a Collection Creating a Collection

Abhijeet Ghosh
Abhijeet Ghosh
5,918 Points

showing error in gettitle

when I am trying to move gettitle and settitle in recipe collection class fatal error is throwing on gettitle

1 Answer

David Evans
David Evans
10,490 Points

Make sure you are copying the methods from recipes.php and not cutting the methods.

In addition, the correct naming convention, unless you changed it, would be getTitle and setTitle.

Hope this helps.