O'Reilly logo

Yii Rapid Application Development Hotshot by James R. Hamilton III, Lauren J. O'Meara

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Adding User Functions – Library

Because we like to share books from our collection with our friends, we will add a lending function to our site. When a friend logs in, he/she will be able to see which books are available for borrowing, which he/she is currently borrowing, and which he/she has borrowed in the past.

Prepare for Lift Off

To demonstrate the effect of lendable/not lendable in the library, edit a few books and turn off the Lendable field.

Engage Thrusters

  1. To access the new feature, we need to add a Library option to the menu, in the file ch4 | Source Files | protected | views | layouts | main.php.
      array('label'=>'Library', 'url'=>array('/library/index')),
    

    Log in to the site and you will see the updated menu, but clicking on this link ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required