Recent Posts Listing

1. Go to AdministersSite buildingsModules (admin/build/modules) and enable the following modules: • Views package

Revisions for Help

Sat, 07/12/2008 - 23:26 by admin Sat, 07/12/2008 - 23:34 by admin

Edited page creation sentence for clarity

< previous diff Changes to Body Line 1

You can quickly create a new page by clicking "Create content > Wiki page" from the navigation menu.

Copy of the revision from Sat, 07/12/2008 - 23:12.

Line 1

You can quickly create a new Wiki page by clicking Create content > Wiki page from the navigation menu.

You can read more about this site's purpose on the [[About the SCA Wiki]] page.

You can read more about this site's purpose on the [[About the SCA Wiki]] page.

Figure 5-15. Diff module highlighting the changes between two revisions of the Help page —Views —Views UI

2. Go to AdministersSite buildings Views (admin/build/views) and click the Enable link for "Default Node view: tracker." Then click the Edit link (admin/build/views/ edit/tracker).

3. Ensure that the Defaults display is highlighted.

4. Limit the visibility of this view to authenticated users by entering the Basic settings shown in Table 5-5, and clicking Update. Select the authenticated user role in the following configuration screen and click Update once more.

Table 5-5. View Basic settings for the "Recent posts" view Defaults: Basic settings Value Access Type: By role

5. As this view is only concerned with updates to content, under Fields, click on the "Node: Last comment time" field and click the Remove button to remove it from the view.

View settings

Tag: default

Relationships

None defined

Sort criteria Node: Post date desc

Basic settings

Name: Defaults

Title: Recent posts

Use AJAX: No

Use pager: Yes

Items per page: 25

More link: No

Distinct: No

Access: authenticated user

Header: None Footer: None Empty text: None Tlieme: Information

Arguments

None defined

Filters

Node: Published True

Fields + it

Node: Type Type

Node; Title Title

User: Name Author

Node: Comment count Replies

Node: Has new content

Node: New comments

Node: Post date Post date

Figure 5-16. Completed recent posts view settings

6. Replace the last comment time with the post date by clicking the (+) (plus) icon in the Fields group and adding the "Node: Post date" field. Give it a Label of "Post date."

7. Because the recent content should be listed across the whole site and not limited per user, under Arguments, click on the User: Uid argument and click the Remove button.

8. As we did with fields, let's sort the list of content by post date rather than last comment time. Under "Sort criteria," click the "Node: Last comment time" field and click the Remove button to remove it from the view.

9. Click the (+) (plus) icon under "Sort criteria" and check the "Node: Post date" field. Switch its sort order to Descending.

10. When finished with these steps, your view should like Figure 5-16. Click the Save button.

11. Click the View "Page" link to take a look at your handiwork. You should see something similar to Figure 5-17.

0 0

Post a comment