Skip to main content

Display Recent Signatures on Petition Page

Is it possible to display the first name and city, state of the 5 most recent signers on a petition page? I don’t want to use the activity stream because I want to display only those who signed not all activities.

Official response from

Hello Edwin,

The petition page should already be displaying the recent signers in the activity stream. Showing location information is not currently supported unless you are displaying that individual user their submitted address in their logged-in session. 

You can, however, do other things with the recent signatures on a petition. These would go in the template of the page.

Show array of user-submitted signature images (if this option is enabled)

{% for signature in page.petition.signatures_with_images limit:20 %}
<a href="{{ signature.signup.profile_url }}"><img src="{{ signature.large_square_image_url }}" border="0" width="48" height="48" class="profile_image" original-title="{{ signature.signup.published_first_name }}" style="border-radius:5px;"></a>
{% endfor %}

Show array of recent signers:
{% for signup in page.petition.recent_signers %}. {{ signup.profile_image }}{{ signup.published_first_name }} {% endfor %}

Show array of random signers:

{% for signup in page.petition.random_signers %}. {{ signup.profile_image }}{{ signup.published_first_name }}{% endfor %}

Show array of random signers that have pictures uploaded:

{% for signup in page.petition.random_signers_with_pictures %}{{ signup.profile_image }} {% endfor %} 

 

-You can find other available signup variables for signup name, and use this method for showing content from a petition page on a different page.

Share this post

Showing 5 reactions

How would you tag this suggestion?
Please check your e-mail for a link to activate your account.