本文整理汇总了PHP中HtmlForm::addLine方法的典型用法代码示例。如果您正苦于以下问题:PHP HtmlForm::addLine方法的具体用法?PHP HtmlForm::addLine怎么用?PHP HtmlForm::addLine使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类HtmlForm
的用法示例。
在下文中一共展示了HtmlForm::addLine方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: fread
// Foto aus PHP-Temp-Ordner einlesen
$user_image_data = fread(fopen($_FILES['userfile']['tmp_name'][0], 'r'), $_FILES['userfile']['size'][0]);
// Zwischenspeichern des neuen Fotos in der Session
$gCurrentSession->setValue('ses_binary', $user_image_data);
$gCurrentSession->save();
}
//Image-Objekt löschen
$user_image->delete();
if ($getItemId == $gCurrentUser->getValue('inv_id')) {
$headline = $gL10n->get('PRO_EDIT_MY_PROFILE_PICTURE');
} else {
$headline = $gL10n->get('PRO_EDIT_PROFILE_PIC_FROM', $inventory->getValue('FIRST_NAME'), $inventory->getValue('LAST_NAME'));
}
// create html page object
$page = new HtmlPage($headline);
$page->addJavascript('$("#btn_cancel").click(function() {
self.location.href=\'' . $g_root_path . '/adm_program/modules/inventory/item_photo_edit.php?mode=dont_save&inv_id=' . $getItemId . '\';
});', true);
// show form
$form = new HtmlForm('show_new_profile_picture_form', $g_root_path . '/adm_program/modules/inventory/item_photo_edit.php?mode=save&inv_id=' . $getItemId, $page);
$form->addCustomContent($gL10n->get('PRO_CURRENT_PICTURE'), '<img class="imageFrame" src="item_photo_show.php?inv_id=' . $getItemId . '" alt="' . $gL10n->get('PRO_CURRENT_PICTURE') . '" />');
$form->addCustomContent($gL10n->get('PRO_NEW_PICTURE'), '<img class="imageFrame" src="item_photo_show.php?inv_id=' . $getItemId . '&new_photo=1" alt="' . $gL10n->get('PRO_NEW_PICTURE') . '" />');
$form->addLine();
$form->openButtonGroup();
$form->addButton('btn_cancel', $gL10n->get('SYS_ABORT'), array('icon' => THEME_PATH . '/icons/error.png'));
$form->addSubmitButton('btn_update', $gL10n->get('SYS_APPLY'), array('icon' => THEME_PATH . '/icons/database_in.png'));
$form->closeButtonGroup();
// add form to html page and show page
$page->addHtml($form->show(false));
$page->show();
}