本文整理汇总了PHP中Fisharebest\Webtrees\Functions\FunctionsPrint::initializeCalendarPopup方法的典型用法代码示例。如果您正苦于以下问题:PHP FunctionsPrint::initializeCalendarPopup方法的具体用法?PHP FunctionsPrint::initializeCalendarPopup怎么用?PHP FunctionsPrint::initializeCalendarPopup使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Fisharebest\Webtrees\Functions\FunctionsPrint
的用法示例。
在下文中一共展示了FunctionsPrint::initializeCalendarPopup方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: print_indi_form
//.........这里部分代码省略.........
break;
case 'add_child_to_individual_action':
if ($person->getSex() === 'F') {
$name_fields = $surname_tradition->newChildNames('', $indi_name, $gender) + $name_fields;
} else {
$name_fields = $surname_tradition->newChildNames($indi_name, '', $gender) + $name_fields;
}
break;
case 'add_parent_to_individual_action':
$name_fields = $surname_tradition->newParentNames($indi_name, $gender) + $name_fields;
break;
case 'add_spouse_to_family_action':
if ($father) {
$name_fields = $surname_tradition->newSpouseNames($father_name, $gender) + $name_fields;
} else {
$name_fields = $surname_tradition->newSpouseNames($mother_name, $gender) + $name_fields;
}
break;
case 'add_spouse_to_individual_action':
$name_fields = $surname_tradition->newSpouseNames($indi_name, $gender) + $name_fields;
break;
case 'add_unlinked_indi_action':
case 'update':
if ($surname_tradition->hasSurnames()) {
$name_fields['NAME'] = '//';
}
break;
}
}
$bdm = '';
// used to copy '1 SOUR' to '2 SOUR' for BIRT DEAT MARR
echo '<div id="edit_interface-page">';
echo '<h4>', $controller->getPageTitle(), '</h4>';
FunctionsPrint::initializeCalendarPopup();
echo '<form method="post" name="addchildform" onsubmit="return checkform();">';
echo '<input type="hidden" name="ged" value="', $WT_TREE->getNameHtml(), '">';
echo '<input type="hidden" name="action" value="', $nextaction, '">';
echo '<input type="hidden" name="fact_id" value="', $name_fact_id, '">';
echo '<input type="hidden" name="xref" value="', $xref, '">';
echo '<input type="hidden" name="famtag" value="', $famtag, '">';
echo '<input type="hidden" name="gender" value="', $gender, '">';
echo '<input type="hidden" name="goto" value="">';
// set by javascript
echo Filter::getCsrf();
echo '<table class="facts_table">';
switch ($nextaction) {
case 'add_child_to_family_action':
case 'add_child_to_individual_action':
// When adding a new child, specify the pedigree
FunctionsEdit::addSimpleTag('0 PEDI');
break;
case 'update':
// When adding/editing a name, specify the type
FunctionsEdit::addSimpleTag('0 TYPE ' . $name_type, '', '', null, $person);
break;
}
// First - new/existing standard name fields
foreach ($name_fields as $tag => $value) {
if (substr_compare($tag, '_', 0, 1) !== 0) {
FunctionsEdit::addSimpleTag('0 ' . $tag . ' ' . $value);
}
}
// Second - new/existing advanced name fields
if ($surname_tradition->hasMarriedNames() || preg_match('/\\n2 _MARNM /', $namerec)) {
$adv_name_fields = array('_MARNM' => '');
} else {
示例2: foreach
<table class="facts_table width40">
<tr><td class="topbottombar" colspan="2">', I18N::translate('Choose a report to run'), '</td></tr>
<tr><td class="descriptionbox wrap width33 vmiddle">', I18N::translate('Report'), '</td>
<td class="optionbox"><select name="report">';
foreach ($reports as $file => $report) {
echo '<option value="', Filter::escapeHtml($file), '">', Filter::escapeHtml($report), '</option>';
}
echo '</select></td></tr>
<tr><td class="topbottombar" colspan="2"><input type="submit" value="', I18N::translate('continue'), '"></td></tr>
</table></form></div>';
break;
case 'setup':
$report_setup = new ReportParserSetup($report);
$report_array = $report_setup->reportProperties();
$controller->setPageTitle($report_array['title'])->pageHeader()->addExternalJavascript(WT_AUTOCOMPLETE_JS_URL)->addInlineJavascript('autocomplete();');
FunctionsPrint::initializeCalendarPopup();
echo '<div id="reportengine-page">
<form name="setupreport" method="get" action="reportengine.php" onsubmit="if (this.output[1].checked) {this.target=\'_blank\';}">
<input type="hidden" name="action" value="run">
<input type="hidden" name="report" value="', Filter::escapeHtml($report), '">
<table class="facts_table width50">
<tr><td class="topbottombar" colspan="2">', I18N::translate('Enter report values'), '</td></tr>
<tr><td class="descriptionbox width30 wrap">', I18N::translate('Report'), '</td><td class="optionbox">', $report_array['title'], '<br>', $report_array['description'], '</td></tr>';
if (!isset($report_array['inputs'])) {
$report_array['inputs'] = array();
}
foreach ($report_array['inputs'] as $input) {
echo '<tr><td class="descriptionbox wrap">';
echo '<input type="hidden" name="varnames[]" value="', Filter::escapeHtml($input["name"]), '">';
echo I18N::translate($input['value']), '</td><td class="optionbox">';
if (!isset($input['type'])) {