Fix - added class-closing } to new MY_Controller code partial

World Wide Web Server 2012-07-04 16:06:29 -07:00
parent 32bb4c93bb
commit bf6b40a60b

@ -81,7 +81,8 @@ Now test your application - it will work exactly the same as it did previously.
[i]If you don't trust me - and good for you if so - you can edit the MY_Controller briefly and introduce an obvious syntax error, such as changing [b]parent[/b] to [b]patent[/b] for example, and then try reloading your page. Revert your error before continuing.[/i]
[b]Theory side note[/b]
[h3]Theory side note[/h3]
All we've done here is inserted this [b]MY_Controller[/b] class in between your normal Controller and the CI Controller class. Previously your Controller was descended directly from the CI core. This is basic OO theory, but if you're not familiar with that then a ludicrous analogy might be that we've just inserted a new generation between you and your dad - with your dad suddenly becoming your grand-dad. You have still inherited the blue eyes and sparkling wit, but it means you can also now inherit (once you create them!) things from this new intermediate ancestor - such as curly hair or date formatters.
@ -138,6 +139,7 @@ class MY_Controller extends Controller {
return $output;
} // end-function pretty_date ()
} // end-class MY_Controller
[/code]