Ruby On Rails Classroom image

Pooja  Negi / Student / Web Technology

 
To post your Question Join Classroom
 
Lesson Topics's No:-  First|1 | 2 | 3 | 4|Last
Lessons:-A Gravatar Image and a Sidebar

 

The code in Listing 7.13 returns an image tag for the Gravatar with a "gravatar" class and alt text equal to the user’s name (which is especially convenient for sight-impaired browsers using a screen reader). You can confirm that the test suite is now passing:

$  bundle  exec  rspec spec/

 

The profile page appears as in Figure 7.7, which shows the default Gravatar image, which appears because user@example.com is an invalid email address (theexample.com domain is reserved for examples).  

             To get our application to display a custom Gravatar, we’ll use update_attributes (Section 6.1.5) to update the user in the database:

 

Here we’ve assigned the user the email address example@railstutorial.org, which I’ve associated with the Rails Tutorial logo, as seen in Figure 7.8. The last element needed to complete the mockup from Figure 7.1 is the initial version of the user sidebar. We’ll implement it using the aside tag, which is used for

 

                       Figure 7.7 The user profile page /users/1 with the default Gravatar.

 
 
 
image
Pooja   Negi

Skills    Ruby On Rails

Qualifications :- High School - SSN high school, College/University - HNBGU, College/University - SRHU,
Location :-Ranipokhari,Rishikesh,Uttarakhand,India
Description:- Student
Explore
 

  Students (0)