function bs_shortcodes_column_attributes in Bootstrap 3 shortcodes 7
File
- includes/
bootstrap-shortcodes-attributes.inc, line 77 - Adds attribute callbacks for shortcode wysiwyg integration @author Jurriaan Roelofs
Code
function bs_shortcodes_column_attributes($form, $form_state) {
$form['xs'] = array(
'#type' => 'select',
'#title' => t('xs'),
'#options' => array(
'' => t('None'),
'1' => t('1'),
'2' => t('2'),
'3' => t('3'),
'4' => t('4'),
'5' => t('5'),
'6' => t('6'),
'7' => t('7'),
'8' => t('8'),
'9' => t('9'),
'10' => t('10'),
'11' => t('11'),
'12' => t('12'),
),
'#states' => array(
'visible' => array(
':input[name="shortcode"]' => array(
'value' => 'column',
),
),
),
'#prefix' => '<div class="col-md-4">',
'#suffix' => '</div>',
);
$form['sm'] = array(
'#type' => 'select',
'#title' => t('sm'),
'#options' => array(
'' => t('None'),
'1' => t('1'),
'2' => t('2'),
'3' => t('3'),
'4' => t('4'),
'5' => t('5'),
'6' => t('6'),
'7' => t('7'),
'8' => t('8'),
'9' => t('9'),
'10' => t('10'),
'11' => t('11'),
'12' => t('12'),
),
'#states' => array(
'visible' => array(
':input[name="shortcode"]' => array(
'value' => 'column',
),
),
),
'#prefix' => '<div class="col-md-4">',
'#suffix' => '</div>',
);
$form['md'] = array(
'#type' => 'select',
'#title' => t('md'),
'#options' => array(
'' => t('None'),
'1' => t('1'),
'2' => t('2'),
'3' => t('3'),
'4' => t('4'),
'5' => t('5'),
'6' => t('6'),
'7' => t('7'),
'8' => t('8'),
'9' => t('9'),
'10' => t('10'),
'11' => t('11'),
'12' => t('12'),
),
'#states' => array(
'visible' => array(
':input[name="shortcode"]' => array(
'value' => 'column',
),
),
),
'#prefix' => '<div class="col-md-4">',
'#suffix' => '</div>',
);
$form['lg'] = array(
'#type' => 'select',
'#title' => t('lg'),
'#options' => array(
'' => t('None'),
'1' => t('1'),
'2' => t('2'),
'3' => t('3'),
'4' => t('4'),
'5' => t('5'),
'6' => t('6'),
'7' => t('7'),
'8' => t('8'),
'9' => t('9'),
'10' => t('10'),
'11' => t('11'),
'12' => t('12'),
),
'#states' => array(
'visible' => array(
':input[name="shortcode"]' => array(
'value' => 'column',
),
),
),
'#prefix' => '<div class="col-md-4">',
'#suffix' => '</div>',
);
$form['offset_xs'] = array(
'#type' => 'select',
'#title' => t('offset_xs'),
'#options' => array(
'' => t('None'),
'1' => t('1'),
'2' => t('2'),
'3' => t('3'),
'4' => t('4'),
'5' => t('5'),
'6' => t('6'),
'7' => t('7'),
'8' => t('8'),
'9' => t('9'),
'10' => t('10'),
'11' => t('11'),
'12' => t('12'),
),
'#states' => array(
'visible' => array(
':input[name="shortcode"]' => array(
'value' => 'column',
),
),
),
'#prefix' => '<div class="col-md-4">',
'#suffix' => '</div>',
);
$form['offset_sm'] = array(
'#type' => 'select',
'#title' => t('offset_sm'),
'#options' => array(
'' => t('None'),
'1' => t('1'),
'2' => t('2'),
'3' => t('3'),
'4' => t('4'),
'5' => t('5'),
'6' => t('6'),
'7' => t('7'),
'8' => t('8'),
'9' => t('9'),
'10' => t('10'),
'11' => t('11'),
'12' => t('12'),
),
'#states' => array(
'visible' => array(
':input[name="shortcode"]' => array(
'value' => 'column',
),
),
),
'#prefix' => '<div class="col-md-4">',
'#suffix' => '</div>',
);
$form['offset_md'] = array(
'#type' => 'select',
'#title' => t('offset_md'),
'#options' => array(
'' => t('None'),
'1' => t('1'),
'2' => t('2'),
'3' => t('3'),
'4' => t('4'),
'5' => t('5'),
'6' => t('6'),
'7' => t('7'),
'8' => t('8'),
'9' => t('9'),
'10' => t('10'),
'11' => t('11'),
'12' => t('12'),
),
'#states' => array(
'visible' => array(
':input[name="shortcode"]' => array(
'value' => 'column',
),
),
),
'#prefix' => '<div class="col-md-4">',
'#suffix' => '</div>',
);
$form['offset_lg'] = array(
'#type' => 'select',
'#title' => t('offset_lg'),
'#options' => array(
'' => t('None'),
'1' => t('1'),
'2' => t('2'),
'3' => t('3'),
'4' => t('4'),
'5' => t('5'),
'6' => t('6'),
'7' => t('7'),
'8' => t('8'),
'9' => t('9'),
'10' => t('10'),
'11' => t('11'),
'12' => t('12'),
),
'#states' => array(
'visible' => array(
':input[name="shortcode"]' => array(
'value' => 'column',
),
),
),
'#prefix' => '<div class="col-md-4">',
'#suffix' => '</div>',
);
$form['pull_xs'] = array(
'#type' => 'select',
'#title' => t('pull_xs'),
'#options' => array(
'' => t('None'),
'1' => t('1'),
'2' => t('2'),
'3' => t('3'),
'4' => t('4'),
'5' => t('5'),
'6' => t('6'),
'7' => t('7'),
'8' => t('8'),
'9' => t('9'),
'10' => t('10'),
'11' => t('11'),
'12' => t('12'),
),
'#states' => array(
'visible' => array(
':input[name="shortcode"]' => array(
'value' => 'column',
),
),
),
'#prefix' => '<div class="col-md-4">',
'#suffix' => '</div>',
);
$form['pull_sm'] = array(
'#type' => 'select',
'#title' => t('pull_sm'),
'#options' => array(
'' => t('None'),
'1' => t('1'),
'2' => t('2'),
'3' => t('3'),
'4' => t('4'),
'5' => t('5'),
'6' => t('6'),
'7' => t('7'),
'8' => t('8'),
'9' => t('9'),
'10' => t('10'),
'11' => t('11'),
'12' => t('12'),
),
'#states' => array(
'visible' => array(
':input[name="shortcode"]' => array(
'value' => 'column',
),
),
),
'#prefix' => '<div class="col-md-4">',
'#suffix' => '</div>',
);
$form['pull_md'] = array(
'#type' => 'select',
'#title' => t('pull_md'),
'#options' => array(
'' => t('None'),
'1' => t('1'),
'2' => t('2'),
'3' => t('3'),
'4' => t('4'),
'5' => t('5'),
'6' => t('6'),
'7' => t('7'),
'8' => t('8'),
'9' => t('9'),
'10' => t('10'),
'11' => t('11'),
'12' => t('12'),
),
'#states' => array(
'visible' => array(
':input[name="shortcode"]' => array(
'value' => 'column',
),
),
),
'#prefix' => '<div class="col-md-4">',
'#suffix' => '</div>',
);
$form['pull_lg'] = array(
'#type' => 'select',
'#title' => t('pull_lg'),
'#options' => array(
'' => t('None'),
'1' => t('1'),
'2' => t('2'),
'3' => t('3'),
'4' => t('4'),
'5' => t('5'),
'6' => t('6'),
'7' => t('7'),
'8' => t('8'),
'9' => t('9'),
'10' => t('10'),
'11' => t('11'),
'12' => t('12'),
),
'#states' => array(
'visible' => array(
':input[name="shortcode"]' => array(
'value' => 'column',
),
),
),
'#prefix' => '<div class="col-md-4">',
'#suffix' => '</div>',
);
$form['push_xs'] = array(
'#type' => 'select',
'#title' => t('push_xs'),
'#options' => array(
'' => t('None'),
'1' => t('1'),
'2' => t('2'),
'3' => t('3'),
'4' => t('4'),
'5' => t('5'),
'6' => t('6'),
'7' => t('7'),
'8' => t('8'),
'9' => t('9'),
'10' => t('10'),
'11' => t('11'),
'12' => t('12'),
),
'#states' => array(
'visible' => array(
':input[name="shortcode"]' => array(
'value' => 'column',
),
),
),
'#prefix' => '<div class="col-md-4">',
'#suffix' => '</div>',
);
$form['push_sm'] = array(
'#type' => 'select',
'#title' => t('push_sm'),
'#options' => array(
'' => t('None'),
'1' => t('1'),
'2' => t('2'),
'3' => t('3'),
'4' => t('4'),
'5' => t('5'),
'6' => t('6'),
'7' => t('7'),
'8' => t('8'),
'9' => t('9'),
'10' => t('10'),
'11' => t('11'),
'12' => t('12'),
),
'#states' => array(
'visible' => array(
':input[name="shortcode"]' => array(
'value' => 'column',
),
),
),
'#prefix' => '<div class="col-md-4">',
'#suffix' => '</div>',
);
$form['push_md'] = array(
'#type' => 'select',
'#title' => t('push_md'),
'#options' => array(
'' => t('None'),
'1' => t('1'),
'2' => t('2'),
'3' => t('3'),
'4' => t('4'),
'5' => t('5'),
'6' => t('6'),
'7' => t('7'),
'8' => t('8'),
'9' => t('9'),
'10' => t('10'),
'11' => t('11'),
'12' => t('12'),
),
'#states' => array(
'visible' => array(
':input[name="shortcode"]' => array(
'value' => 'column',
),
),
),
'#prefix' => '<div class="col-md-4">',
'#suffix' => '</div>',
);
$form['push_lg'] = array(
'#type' => 'select',
'#title' => t('push_lg'),
'#options' => array(
'' => t('None'),
'1' => t('1'),
'2' => t('2'),
'3' => t('3'),
'4' => t('4'),
'5' => t('5'),
'6' => t('6'),
'7' => t('7'),
'8' => t('8'),
'9' => t('9'),
'10' => t('10'),
'11' => t('11'),
'12' => t('12'),
),
'#states' => array(
'visible' => array(
':input[name="shortcode"]' => array(
'value' => 'column',
),
),
),
'#prefix' => '<div class="col-md-4">',
'#suffix' => '</div>',
);
$form['xclass'] = array(
'#type' => 'textfield',
'#title' => t('xclass'),
'#size' => 30,
'#maxlength' => 30,
'#states' => array(
'visible' => array(
':input[name="shortcode"]' => array(
'value' => 'column',
),
),
),
);
$form['data'] = array(
'#type' => 'textfield',
'#title' => t('data'),
'#size' => 30,
'#maxlength' => 30,
'#states' => array(
'visible' => array(
':input[name="shortcode"]' => array(
'value' => 'column',
),
),
),
);
return $form;
}