You are here

function fbconnect_render_friends_invite_form in Facebook Connect 6

Same name and namespace in other branches
  1. 5 fbconnect.module \fbconnect_render_friends_invite_form()

Render the facebook friends invite form.

1 string reference to 'fbconnect_render_friends_invite_form'
fbconnect_menu in ./fbconnect.module
Implementation of hook_menu().

File

./fbconnect.pages.inc, line 266

Code

function fbconnect_render_friends_invite_form() {
  global $base_url;
  $site = drupal_to_js(variable_get('site_name', $base_url));
  $actiontxt = drupal_to_js(t('Please select the Facebook friends you want to invite'));
  $action = drupal_to_js(variable_get('fbconnect_invite_dest', $base_url));
  $type = drupal_to_js(variable_get('fbconnect_invite_name', $site));
  $content = check_plain(variable_get('fbconnect_invite_msg', t('Enjoy'))) . '  <fb:req-choice url=\'' . $base_url . '\' label=\'Become a Member!\' />';
  $output = '<fb:serverfbml>
                <script type="text/fbml">
                  <fb:fbml>
                    <fb:request-form
                      action=' . $action . '
                      method="POST"
                      invite="true"
                      type=' . $type . '
                      content="' . $content . '">
                      <fb:multi-friend-selector
                      cols="6"
                      rows="6"
                      showborder="false"
                      actiontext=' . $actiontxt . '
                      max="35"
                      bypass="cancel" />
                    </fb:request-form>
                  </fb:fbml>
                </script>
              </fb:serverfbml>';
  return $output;
}