Looking For Something?

[wps-activity]

Purpose

Displays activity feed of the user.

This powerful shortcode displays all the activity of a member (their activity stream), and any other activity posts of other members that they have permission to view. In addition to showing the activity post, members can then also comment on the post.

When an activity post has a comment added to it, it will move to the top of the activity stream (as most recently active).

The user, or site administrator, can delete a post and it’s associated comments by hovering over the settings icon (wrench) and choosing “Delete”.

A member can also hide another member’s post.

Users can also choose to make a post “stick” to the top of their activity stream, perhaps because it’s particularly important. This is also available by hovering over the wrench settings icon.

Emoticons will automatically be converted into graphical representations if set on via the admin dashboard, Settings->Writing.

There are quite a lot of options for this shortcode! The best thing to do is play around with them, see how they change the activity stream, and choose the parameters that you like best for your site.

A typical activity stream will look like this:

Screenshot_4

Availability

Provided in the Core Plugin.

Customising

You can use the global shortcode settings via WPS Pro->Shortcodes in the admin dashboard, or add them to the shortcode as options.

Example

[wps-activity avatar_size="128" comment_avatar_size="40"]

Options

The following (which shows default values and an example of using the shortcode option) can be set via the admin dashboard (WPS Pro->Shortcodes) or added as options to the shortcode in your WordPress page, post or widget.

Shortcode options

Include user’s own activity

(include_self=”1″)
Whether or not to include the user’s activity in the activity stream.

Include user’s friends activity

(include_friends=”1″)
Whether or not to include activity from the user’s friends or not. Increases load on server if you do.

How long since friend has been active for activity to be included

(active_friends=”30″)
Exclude inactive friends since ‘x’ number of days.

Number of activity items shown at a time

(page_size=”10″)
How many to show before loading more, keep lower to improve performance.

Maximum activity posts retrieved for user

(get_max=”50″)
Avoid adding to the load on your server by keeping this number smaller.

Maximum activity posts retrieved from friends

(get_max_friends=”50″)
Avoid adding to the load on your server by keeping this number smaller.

Avatar size

(avatar_size=”64″)
The size of the user’s avatar shown beside the activity post.

Word limit for posts

(more=”50″)
The maximum number of words allowed in a single post.

Text to show reset of truncated posts

(more_label=”more”)
When long posts are truncated, what word should be shown to click on to show the rest of the post.

Hide activity until fully loaded

(hide_until_loaded=”0″)
Set this to wait until all activity has loaded before showing it, can make the page load appearance more managed.

Comment avatar size

(comment_avatar_size=”40″)
Avatar size for comment.

Number of comments shown

(comment_size=”5″)
Number of comments shown, previous ones are hidden.

Text for multiple previous comments

(comment_size_text_plural=”Show previous %d comments…”)
Text that is shown if there are 2+ previous comments.

Text for one previous comment

(comment_size_text_singular=”Show previous comment…”)
Text that is shown if there is 1 previous comment.

Label for Comment button

(label=”Comment”)
Erm… label for the comment button.

Optional CSS class for button

(class=””)
Add a CSS class to the button.

User names link to profile page

(link=”1″)
Whether or not user names link to their profile page.

Activity is private message

(private_msg=”Activity is private”)
Message shown if activity cannot be seen due to privacy settings.

Post no longer exists message

(not_found=”Sorry, this activity post is not longer available.”)
Message shown if the message no longer exists, probably deleted.

Delete option label

(delete_label=”Delete”)
Word(s) for the delete option.

Stick option label

(sticky_label=”Stick”)
Word(s) for the stick option.

Unstick option label

(unsticky_label=”Unstick”)
Word(s) for the unstick option.

Hide option label

(hide_label=”Hide”)
Word(s) for the hide option.

Include Report option

(report=”1″)
Whether or not the report option is shown.

Report option label

(report_label=”Report”)
The label for the report option if shown.

Report email recipient

(report_email=”[email protected]”)
An email address where reports are sent.

Honour friends sticky posts

(stick_others=”0″)
If a friend’s post is sticky, should it also be sticky on the user’s profile activity.

Allow comments

(allow_replies=”1″)
Should comments be allowed.

Date format

(date_format=”%s ago”)
Format of the date, %s is used to replace how long ago the post was made.

Logged out message

(logged_out_msg=”You must be logged in to view the profile page.”)
Message shown if you need to be logged in to see the activity.

Optional URL to login

(login_url=””)
An optional link to login, combined with the above.

Activate flip/rotate for images

(effects=”0″)
Should flip and rotate options be shown for images.

Website link (URL) previews

Dynamic Previews (no caching)

(dynamic_previews=”0″)
If a link is entered, a previous of the site can be shown. Note that this adds significant load to a server as an additional call is made to that server and response times cannot be guaranteed, and is not recommend generally. Not every website will permit this feature, so not every link can generate a preview. If successfully accessed, the first image found that meets the criteria below is used, along with the site’s title and description (from meta data).

Max Previews

(max_previews=”10″)
How many posts, with links, should show previews. Keep to a minimum to reduce server load.

Preview image size

(url_preview_image=”100″)
Size of the preview image.

Enable image fail

(url_preview_fail=”1″)
If an image cannot be retried, should it be allowed to fail?

Minimum width used

(min_width=”200″)
Smallest size of images used for the preview.

Maximum width used

(max_width=”0″)
Largest size of images used for the preview.

Fail text

(fail_text=”Unable to connect to site”)
Text to show if previous fails.

Fail image

(fail_image=”http://localhost/wp-content/plugins/wp-symposium-pro-extensions/wp-symposium-pro-activity-url-preview/broken.png”)
Image to show if the image fails, or one is not found.

Images to ignore

(ignore_images=”adserver,ads,affiliate”)
A comma separated list of any words in an images domain to ignore, useful to exclude adverts (eg. “adserver,ads,affiliate”).

Url words to ignore

(ignore_links=””)
Any URLs to ignore that contain words as a comma separated list (eg. “boobs,bums”).

Share activity with Facebook

Facebook share message (share_msg=”Share post on Facebook as”)
Facebook connect message (connect_msg=”Connect to Facebook”)
Facebook connect message (disconnect_msg=”Disconnect”)

Likes and Dislikes

Enable likes (allow_likes=”0″)
Like label (like_text=”Like”)
Unlike label (unlike_text=”Unlike”)
Like text (singular) (like_count_text_singular=”%d like”)
Like text (plural) (like_count_text_plural=”%d likes”)
Enable dislikes (allow_dislikes=”0″)
Dislike label (dislike_text=”Dislike”)
Undislike label (undislike_text=”Undislike”)
Dislike text (singular) (dislike_count_text_singular=”%d dislike”)
Dislike text (plural) (dislike_count_text_plural=”%d dislikes”)
Done text (done_text=”Done!”)
by text (by_text=” by “)
or text (or_text=” or “)
you text (you_text=”you”)
more text (singular) (more_text_singular=”and %d more…”)
more text (plural) (more_text_plural=”and %d more…”)
Maximum names to show (max_names_to_show=”3″)
Sidebar