<?xml version="1.0" encoding="UTF-8"?>
<!-- generator="bbPress/1.0.1" -->
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom">
	<channel>
		<title>Gravity Support Forums Topic: Gravity Forms &#38; Buddypress, bp_activity_add</title>
		<link>https://legacy.forums.gravityhelp.com/topic/gravity-forms-buddypress-bp_activity_add</link>
		<description>Gravity Support Forums Topic: Gravity Forms &amp; Buddypress, bp_activity_add</description>
		<language>en-US</language>
		<pubDate>Sat, 04 Apr 2026 15:50:30 +0000</pubDate>
		<generator>http://bbpress.org/?v=1.0.1</generator>
		<textInput>
			<title><![CDATA[Search]]></title>
			<description><![CDATA[Search all topics from these forums.]]></description>
			<name>q</name>
			<link>https://legacy.forums.gravityhelp.com/search.php</link>
		</textInput>
		<atom:link href="https://legacy.forums.gravityhelp.com/rss/topic/gravity-forms-buddypress-bp_activity_add" rel="self" type="application/rss+xml" />

		<item>
			<title>Carl Hancock on "Gravity Forms &#38; Buddypress, bp_activity_add"</title>
			<link>https://legacy.forums.gravityhelp.com/topic/gravity-forms-buddypress-bp_activity_add#post-29905</link>
			<pubDate>Wed, 13 Jul 2011 15:52:17 +0000</pubDate>
			<dc:creator>Carl Hancock</dc:creator>
			<guid isPermaLink="false">29905@https://legacy.forums.gravityhelp.com/</guid>
			<description>&#60;p&#62;I'm not familiar enough with BuddyPress to know how the bp_activity_add function call works.  Based on your code it looks like you are on the right track as far as implementing it using the gform_post_submission hook. Can you provide more information on what exactly this function call does and what appears in BuddyPress?
&#60;/p&#62;</description>
		</item>
		<item>
			<title>Kevin Flahaut on "Gravity Forms &#38; Buddypress, bp_activity_add"</title>
			<link>https://legacy.forums.gravityhelp.com/topic/gravity-forms-buddypress-bp_activity_add#post-29878</link>
			<pubDate>Wed, 13 Jul 2011 09:05:13 +0000</pubDate>
			<dc:creator>Kevin Flahaut</dc:creator>
			<guid isPermaLink="false">29878@https://legacy.forums.gravityhelp.com/</guid>
			<description>&#60;p&#62;I'm not sure about your first request but I'm sure someone will answer that for you. Why are you requesting a refund? Is there some other issue we can help you with?
&#60;/p&#62;</description>
		</item>
		<item>
			<title>thinkluke on "Gravity Forms &#38; Buddypress, bp_activity_add"</title>
			<link>https://legacy.forums.gravityhelp.com/topic/gravity-forms-buddypress-bp_activity_add#post-29877</link>
			<pubDate>Wed, 13 Jul 2011 07:25:43 +0000</pubDate>
			<dc:creator>thinkluke</dc:creator>
			<guid isPermaLink="false">29877@https://legacy.forums.gravityhelp.com/</guid>
			<description>&#60;p&#62;Can I get my money baccccck?
&#60;/p&#62;</description>
		</item>
		<item>
			<title>thinkluke on "Gravity Forms &#38; Buddypress, bp_activity_add"</title>
			<link>https://legacy.forums.gravityhelp.com/topic/gravity-forms-buddypress-bp_activity_add#post-29849</link>
			<pubDate>Tue, 12 Jul 2011 20:04:10 +0000</pubDate>
			<dc:creator>thinkluke</dc:creator>
			<guid isPermaLink="false">29849@https://legacy.forums.gravityhelp.com/</guid>
			<description>&#60;p&#62;Hi, does anyone know how to use gravity forms to submit a post from the frontend that uses bp_activity_add in the after form submission to update buddypress activity stream to including the thumbnail image? &#60;/p&#62;
&#60;p&#62;Here is my code so far:&#60;/p&#62;
&#60;pre&#62;&#60;code&#62;add_filter(&#38;quot;gform_post_submission_1&#38;quot;, &#38;quot;set_post_thumbnail_as&#38;quot;, 10, 2);
function set_post_thumbnail_as($entry, $form){

    //getting first image associated with the post
    $post_id = $entry[&#38;quot;post_id&#38;quot;];
    $attachments = get_posts(array(&#38;#39;numberposts&#38;#39; =&#38;gt; &#38;#39;1&#38;#39;, &#38;#39;post_parent&#38;#39; =&#38;gt; $post_id, &#38;#39;post_type&#38;#39; =&#38;gt; &#38;#39;attachment&#38;#39;, &#38;#39;post_mime_type&#38;#39; =&#38;gt; &#38;#39;image&#38;#39;, &#38;#39;order&#38;#39; =&#38;gt; &#38;#39;ASC&#38;#39;));
    if(sizeof($attachments) == 0)
        return; //no images attached to the post

    //setting first image as the thumbnail for this post
    update_post_meta( $post_id, &#38;#39;_thumbnail_id&#38;#39;, $attachments[0]-&#38;gt;ID);

	// update bp activty stream content.
	$activity_id = bp_activity_add( array( &#38;#39;id&#38;#39; =&#38;gt; $post_id, &#38;#39;content&#38;#39; =&#38;gt; &#38;#39;$attachments&#38;#39; ));
}&#60;/code&#62;&#60;/pre&#62;
&#60;p&#62;If someone could help that'd be great
&#60;/p&#62;</description>
		</item>

	</channel>
</rss>
