function pardot_admin_scoring in Pardot Integration 6
Same name and namespace in other branches
- 7.2 pardot.admin-scoring.inc \pardot_admin_scoring()
- 7 pardot.admin-scoring.inc \pardot_admin_scoring()
Form callback for managing and viewing scoring entries.
1 string reference to 'pardot_admin_scoring'
- pardot_menu in ./
pardot.module - Implementation of hook_menu().
File
- ./
pardot.admin-scoring.inc, line 6
Code
function pardot_admin_scoring() {
$form = array();
$scores = db_query('SELECT * FROM {pardot_scoring}');
while ($score = db_fetch_object($scores)) {
$form['scores'][$score->scoring_id] = array(
'#score' => $score,
'path' => array(
'#value' => $score->path,
),
'score' => array(
'#value' => $score->score,
),
);
}
$form['new'] = array(
'path' => array(
'#prefix' => '<div class="add-new-placeholder">' . t('Add new path') . '</div>',
'#type' => 'textfield',
'#size' => 30,
),
'score' => array(
'#prefix' => '<div class="add-new-placeholder"></div>',
'#type' => 'textfield',
'#size' => 30,
),
);
$form['add'] = array(
'#prefix' => '<div class="add-new-placeholder"></div>',
'#type' => 'submit',
'#value' => t('Add'),
);
return $form;
}