Forms API 中的表单控件是否有 id?下面是我的示例代码:
function myid_user_page_form(){
$form = array();
$form['id'] = array(
'#type' => 'fieldset',
'#title' => t('ID Information'),
'#collapsible' => TRUE,
'#collapsed' => FALSE,
);
$form['id']['myphoto_button'] = array(
'#type' => 'button',
'#value' => '...',
'#attributes' => array(
'onclick' => "myphoto_options();",),
);
return $form;
}
对于这个非常简单的初学者问题很抱歉,但是如何在上面的示例中识别我的按钮 ID(例如)$form['id']['myphoto_button']?