latest stable versions: v150827 (changelog)

Old Forums (READ-ONLY): The community now lives at WP Sharks™. If you have an s2Member® Pro question, please use our new Support System.

loop through profile fields and populate

Home Forums Community Forum loop through profile fields and populate

This topic contains 1 reply, has 2 voices. Last updated by  Mike (Volunteer Moderator) 3 years, 5 months ago.

Topic Author Topic
Posted: Monday Jul 22nd, 2013 at 1:28 pm #53818
Mike Waller
Username: seozones

Hi there. I am using Gravity forms on my site along with s2member Pro. In my gravity form, I need to loop through a few fields and display in a GF dropdown field some of that data. Any ideas on how I could accomplish that? I am using the following in my functions.php page to display individual s2member profile data into a single GF field:

add_filter("gform_field_value_display_name", "display_name");
function display_name($value){
$display_name = get_user_field ("display_name");
return $display_name;
}

I also saw this on the GF site which is used to dynamically populate drop down fields:

'Select a Post', 'value' => ' '));
       
       foreach($posts as $post){
           $choices[] = array('text' => $post->post_title, 'value' => $post->post_title);
       }
       
       $field['choices'] = $choices;
       
   }
   
   return $form;
}

…but that is for displaying posts within a GF drop down field. I need to do the same but display a few fields from my s2member profile page. Any ideas?

  • This topic was modified 3 years, 5 months ago by  Eduan. Reason: Moved to the customers forum
  • This topic was modified 3 years, 4 months ago by  Mike Waller.

List Of Topic Replies

Viewing 1 replies (of 1 total)
Author Replies
Author Replies
Posted: Sunday Aug 4th, 2013 at 8:02 pm #55160
Moderator
Related to a 3rd party plugin.
Moving this to community forums where it will gain greater exposure.
Viewing 1 replies (of 1 total)

This topic is closed to new replies. Topics with no replies for 2 weeks are closed automatically.

Old Forums (READ-ONLY): The community now lives at WP Sharks™. If you have an s2Member® Pro question, please use our new Support System.

Contacting s2Member: Please use our Support Center for bug reports, pre-sale questions & technical assistance.