<?php
namespace PHPMaker2019\project_germanos;

// Session
if (session_status() !== PHP_SESSION_ACTIVE)
	session_start(); // Init session data

// Output buffering
ob_start(); 

// Autoload
include_once "autoload.php";
?>
<?php

// Write header
WriteHeader(FALSE);

// Create page object
$titles_delete = new titles_delete();

// Run the page
$titles_delete->run();

// Setup login status
SetupLoginStatus();
SetClientVar("login", LoginStatus());

// Global Page Rendering event (in userfn*.php)
Page_Rendering();

// Page Rendering event
$titles_delete->Page_Render();
?>
<?php include_once "header.php" ?>
<script>

// Form object
currentPageID = ew.PAGE_ID = "delete";
var ftitlesdelete = currentForm = new ew.Form("ftitlesdelete", "delete");

// Form_CustomValidate event
ftitlesdelete.Form_CustomValidate = function(fobj) { // DO NOT CHANGE THIS LINE!

	// Your custom validation code here, return false if invalid.
	return true;
}

// Use JavaScript validation or not
ftitlesdelete.validateRequired = <?php echo json_encode(CLIENT_VALIDATE) ?>;

// Dynamic selection lists
// Form object for search

</script>
<script>

// Write your client script here, no need to add script tags.
</script>
<?php $titles_delete->showPageHeader(); ?>
<?php
$titles_delete->showMessage();
?>
<form name="ftitlesdelete" id="ftitlesdelete" class="form-inline ew-form ew-delete-form" action="<?php echo CurrentPageName() ?>" method="post">
<?php if ($titles_delete->CheckToken) { ?>
<input type="hidden" name="<?php echo TOKEN_NAME ?>" value="<?php echo $titles_delete->Token ?>">
<?php } ?>
<input type="hidden" name="t" value="titles">
<input type="hidden" name="action" id="action" value="delete">
<?php foreach ($titles_delete->RecKeys as $key) { ?>
<?php $keyvalue = is_array($key) ? implode($COMPOSITE_KEY_SEPARATOR, $key) : $key; ?>
<input type="hidden" name="key_m[]" value="<?php echo HtmlEncode($keyvalue) ?>">
<?php } ?>
<div class="card ew-card ew-grid">
<div class="<?php if (IsResponsiveLayout()) { ?>table-responsive <?php } ?>card-body ew-grid-middle-panel">
<table class="table ew-table">
	<thead>
	<tr class="ew-table-header">
<?php if ($titles->Title->Visible) { // Title ?>
		<th class="<?php echo $titles->Title->headerCellClass() ?>"><span id="elh_titles_Title" class="titles_Title"><?php echo $titles->Title->caption() ?></span></th>
<?php } ?>
<?php if ($titles->TitleEn->Visible) { // TitleEn ?>
		<th class="<?php echo $titles->TitleEn->headerCellClass() ?>"><span id="elh_titles_TitleEn" class="titles_TitleEn"><?php echo $titles->TitleEn->caption() ?></span></th>
<?php } ?>
<?php if ($titles->Salutation->Visible) { // Salutation ?>
		<th class="<?php echo $titles->Salutation->headerCellClass() ?>"><span id="elh_titles_Salutation" class="titles_Salutation"><?php echo $titles->Salutation->caption() ?></span></th>
<?php } ?>
<?php if ($titles->SalutationEn->Visible) { // SalutationEn ?>
		<th class="<?php echo $titles->SalutationEn->headerCellClass() ?>"><span id="elh_titles_SalutationEn" class="titles_SalutationEn"><?php echo $titles->SalutationEn->caption() ?></span></th>
<?php } ?>
<?php if ($titles->Notes->Visible) { // Notes ?>
		<th class="<?php echo $titles->Notes->headerCellClass() ?>"><span id="elh_titles_Notes" class="titles_Notes"><?php echo $titles->Notes->caption() ?></span></th>
<?php } ?>
	</tr>
	</thead>
	<tbody>
<?php
$titles_delete->RecCnt = 0;
$i = 0;
while (!$titles_delete->Recordset->EOF) {
	$titles_delete->RecCnt++;
	$titles_delete->RowCnt++;

	// Set row properties
	$titles->resetAttributes();
	$titles->RowType = ROWTYPE_VIEW; // View

	// Get the field contents
	$titles_delete->loadRowValues($titles_delete->Recordset);

	// Render row
	$titles_delete->renderRow();
?>
	<tr<?php echo $titles->rowAttributes() ?>>
<?php if ($titles->Title->Visible) { // Title ?>
		<td<?php echo $titles->Title->cellAttributes() ?>>
<span id="el<?php echo $titles_delete->RowCnt ?>_titles_Title" class="titles_Title">
<span<?php echo $titles->Title->viewAttributes() ?>>
<?php echo $titles->Title->getViewValue() ?></span>
</span>
</td>
<?php } ?>
<?php if ($titles->TitleEn->Visible) { // TitleEn ?>
		<td<?php echo $titles->TitleEn->cellAttributes() ?>>
<span id="el<?php echo $titles_delete->RowCnt ?>_titles_TitleEn" class="titles_TitleEn">
<span<?php echo $titles->TitleEn->viewAttributes() ?>>
<?php echo $titles->TitleEn->getViewValue() ?></span>
</span>
</td>
<?php } ?>
<?php if ($titles->Salutation->Visible) { // Salutation ?>
		<td<?php echo $titles->Salutation->cellAttributes() ?>>
<span id="el<?php echo $titles_delete->RowCnt ?>_titles_Salutation" class="titles_Salutation">
<span<?php echo $titles->Salutation->viewAttributes() ?>>
<?php echo $titles->Salutation->getViewValue() ?></span>
</span>
</td>
<?php } ?>
<?php if ($titles->SalutationEn->Visible) { // SalutationEn ?>
		<td<?php echo $titles->SalutationEn->cellAttributes() ?>>
<span id="el<?php echo $titles_delete->RowCnt ?>_titles_SalutationEn" class="titles_SalutationEn">
<span<?php echo $titles->SalutationEn->viewAttributes() ?>>
<?php echo $titles->SalutationEn->getViewValue() ?></span>
</span>
</td>
<?php } ?>
<?php if ($titles->Notes->Visible) { // Notes ?>
		<td<?php echo $titles->Notes->cellAttributes() ?>>
<span id="el<?php echo $titles_delete->RowCnt ?>_titles_Notes" class="titles_Notes">
<span<?php echo $titles->Notes->viewAttributes() ?>>
<?php echo $titles->Notes->getViewValue() ?></span>
</span>
</td>
<?php } ?>
	</tr>
<?php
	$titles_delete->Recordset->moveNext();
}
$titles_delete->Recordset->close();
?>
</tbody>
</table>
</div>
</div>
<div>
<button class="btn btn-primary ew-btn" name="btn-action" id="btn-action" type="submit"><?php echo $Language->phrase("DeleteBtn") ?></button>
<button class="btn btn-default ew-btn" name="btn-cancel" id="btn-cancel" type="button" data-href="<?php echo $titles_delete->getReturnUrl() ?>"><?php echo $Language->phrase("CancelBtn") ?></button>
</div>
</form>
<?php
$titles_delete->showPageFooter();
if (DEBUG_ENABLED)
	echo GetDebugMessage();
?>
<script>

// Write your table-specific startup script here
// document.write("page loaded");

</script>
<?php include_once "footer.php" ?>
<?php
$titles_delete->terminate();
?>
