X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?p=catagits%2FCatalyst-Manual.git;a=blobdiff_plain;f=lib%2FCatalyst%2FManual%2FTutorial%2F03_MoreCatalystBasics.pod;h=c92075ceb8fd89095d6f9eadcb97499afb8c070b;hp=23c60779f997d9ed83a96c8a8fe2f40d405cef2d;hb=0ed3df53a9644cf30fe2a79828fd2e15044dbcd6;hpb=3c700304aa69d7d4744523fa1f264a2e07c4315c diff --git a/lib/Catalyst/Manual/Tutorial/03_MoreCatalystBasics.pod b/lib/Catalyst/Manual/Tutorial/03_MoreCatalystBasics.pod index 23c6077..c92075c 100644 --- a/lib/Catalyst/Manual/Tutorial/03_MoreCatalystBasics.pod +++ b/lib/Catalyst/Manual/Tutorial/03_MoreCatalystBasics.pod @@ -303,9 +303,9 @@ and add the following method to the controller: # Retrieve all of the book records as book model objects and store in the # stash where they can be accessed by the TT template - # $c->stash->{books} = [$c->model('DB::Book')->all]; + # $c->stash(books => [$c->model('DB::Book')->all]); # But, for now, use this code until we create the model later - $c->stash->{books} = ''; + $c->stash(books => ''); # Set the TT template to use. You will almost always want to do this # in your action methods (action methods respond to user input in @@ -857,7 +857,7 @@ and delete the next 2 lines): # Retrieve all of the book records as book model objects and store # in the stash where they can be accessed by the TT template - $c->stash->{books} = [$c->model('DB::Book')->all]; + $c->stash(books => [$c->model('DB::Book')->all]); # Set the TT template to use. You will almost always want to do this # in your action methods (action methods respond to user input in @@ -1555,7 +1555,7 @@ has changed): # Retrieve all of the book records as book model objects and store in the # stash where they can be accessed by the TT template - $c->stash->{books} = [$c->model('DB::Book')->all]; + $c->stash(books => [$c->model('DB::Book')->all]); # Set the TT template to use. You will almost always want to do this # in your action methods (actions methods respond to user input in @@ -1582,7 +1582,7 @@ In order to be able to use C<$c-Eforward> and C<$c-Edetach> later in the tutorial, you should remove the comment from the statement in C in C: - $c->stash->{template} = 'books/list.tt2'; + $c->stash(template => 'books/list.tt2'); Then delete the C line in C.