What do I need to do to output text instruction between the page heading and the first form element?

This is the function for the form page

// Form STEP 1
// membership form to select membership type
function membership_member_select_form(){
	
    $form = array(); //an array to hold our form
    
    // build the form input fields
    # the options to display in our form radio buttons
	$options = array(
	  'individual' => t('Individual Membership'),
	  'family' => t('Family Membership'), 
	  'new_ham' => t('New Ham, (less than a year)'),
	  'student' => t('Student (full time'),
	);

	$form['membership_type'] = array(
	  '#type' => 'radios',
	  '#title' => t('What type of membership are you requesting?'),
	  '#options' => $options,
	  '#description' => t('Individual is our default membership, "New Ham" is a discounted individual membership for anyone that has obtained a license in the last year.  Students must be full time students at accredited schools or university.'),
	  '#default_value' => $options['individual'],
	);

    // the submit button
    $form['submit'] = array(
        '#type' => 'submit',
        '#value' => 'Continue to Payment'
    );
    
    // tell Drupal what to do with this for submission
    $form['#submit'][]='membership_member_form_submit_1';
        
    return $form;
}

Comments

jaypan’s picture

$form['text_header'] = array
(
  '#prefix' => '<p>',
  '#suffix' => '</p>',
  '#markup' => t('Text Header'),
  '#weight' => -100,
);

Contact me to contract me for D7 -> D10/11 migrations.

Me’s picture

Thank you that works good.

Is there any way to just include normal markup? I am not interested in it being translated.

jaypan’s picture

Yeah. Just put in your markup as-is.

Contact me to contract me for D7 -> D10/11 migrations.