本文整理匯總了PHP中Modal函數的典型用法代碼示例。如果您正苦於以下問題:PHP Modal函數的具體用法?PHP Modal怎麽用?PHP Modal使用的例子?那麽, 這裏精選的函數代碼示例或許可以為您提供幫助。
在下文中一共展示了Modal函數的10個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。
示例1: Modal
?>
</tbody>
</table>
</div>
</div>
</div>
</div>
</div>
</section>
</div>
<script>
$(document).ready(function() {
$('#dataTables').DataTable({
"scrollY":"400px",
"scrollX": true,
dom: 'Bfrtip',
buttons: [
{
extend:"excel",
text:"<span style='color:#fff'><span class='fa fa-download'></span> Download Excel </span>",
className:"btn btn-success btn-flat",
"extension":".xls"
}
]
});
});
</script>
<?php
Modal();
makeFoot();
示例2: mysql_query
}
/*
Handles Request for viewing spell data in a Modal
*/
if (isset($_GET['spellview'])) {
require_once 'includes/spell.inc.php';
require_once 'includes/alla_functions.php';
if ($_GET['spellview'] > 0) {
$QueryResult = mysql_query("SELECT * FROM spells_new WHERE `id` = " . $_GET['spellview'] . ";");
while ($row = mysql_fetch_array($QueryResult)) {
$Content .= BuildSpellInfo($row, 1);
}
} else {
$Content .= 'There is currently no spell data...<br>';
}
echo Modal('View Spell Data', '<div class="alert alert-info">' . $Content . '</div>', '');
}
/*
Displays Item View tooltip
*/
if (isset($_GET['item_view'])) {
require_once 'includes/constants.php';
require_once 'includes/alla_functions.php';
require_once 'modules/ItemEditor/constants_ie.php';
// echo '<style></style>';
$QueryResult = mysql_query("SELECT * FROM items WHERE `id` = " . $_GET['item_view'] . ";");
while ($row = mysql_fetch_array($QueryResult)) {
// $Content .= BuildSpellInfo($row, 1);
echo BuildItemStats($row, 1, 'item_view');
}
}
示例3: Modal
</tr>
<tr>
<td style="text-align:right">Number of NPC Copies to make</td>
<td><input type="text" class="form-control" value="1" id="copies_to_make"></td>
</tr>
<tr>
<td></td>
<td><button type="button" class="btn btn-default btn-sm btn-xs" onclick="do_npc_copy_confirm(' . $_GET['npc_copy'] . ')" title="Copy NPC"><i class="fa fa-sign-in"></i> Copy NPC</button></td>
</tr>
<tr>
<td></td>
<td><div id="npc_copy_result"></div></td>
</tr>
</table>
</center>';
echo Modal('Copy NPC', $Content, '');
}
/* Get Field Translator on double click of cell */
if (isset($_GET['get_field_translator'])) {
echo GetFieldSelect($_GET['field_name'], $_GET['value'], $_GET['npc_id'], 1);
}
/* Actual Delete */
if ($_GET['delete_npc']) {
mysql_query("DELETE FROM `npc_types` WHERE `id` = " . $_GET['delete_npc']);
mysql_query("DELETE FROM `spawnentry` WHERE `npcID` = " . $_GET['delete_npc']);
}
/* Update NPC Data Field */
if ($_GET['DoFieldUpdate']) {
$query = "UPDATE `npc_types` SET `" . $_GET['Field'] . "` = '" . $_GET['Value'] . "' WHERE `id` = " . $_GET['NPC'] . "";
echo $query;
$result = mysql_query($query);
示例4: foreach
if ($order_val != '') {
$Content .= '<br><span class="label label-danger badge" style="font-weight:bold">' . $order_val . '</span><br><br>';
}
$Content .= '<table class="table-bordered table-striped table-condensed flip-content single_edit_table" style="width:70%">';
foreach ($npc_fields[$order_val] as $key => $val) {
#print $key . '<br>';
if ($key == "d_melee_texture1" || $key == "d_melee_texture2" || $key == "race") {
$td_content .= '
<td style="text-align:center;vertical-align:top">' . $val[1] . '<br><b>' . $val[0] . '</b></td>';
} else {
$td_content .= '
<td style="text-align:right;"><b>' . $val[0] . '</b> </td><td> ' . $val[1] . ' </td>';
}
$n++;
if ($n == 3) {
$Content .= '<tr>' . $td_content . '</tr>';
$td_content = "";
$n = 0;
}
}
if ($td_content != "") {
$Content .= '<tr>' . $td_content . '</tr>';
$td_content = "";
$n = 0;
}
$Content .= '</table>';
}
$Content .= '</table>';
echo '<script type="text/javascript" src="modules/NPC/ajax/single_npc_edit.js"></script>';
echo Modal('NPC Edit', $Content, '');
}
示例5: toLogin
toLogin();
die;
}
if (empty($_GET['id'])) {
redirect("assets.php");
die;
} else {
$id = $_GET['id'];
}
require_once 'class/BCGFontFile.php';
require_once 'class/BCGColor.php';
require_once 'class/BCGDrawing.php';
require_once 'class/BCGcode128.barcode.php';
$asset = $con->myQuery("SELECT asset_tag,asset_name,model FROM qry_assets WHERE id=?", array($id))->fetch(PDO::FETCH_ASSOC);
if (empty($asset)) {
Modal("Asset does not Exist.");
redirect("index.php");
die;
}
try {
$colorFront = new BCGColor(0, 0, 0);
$colorBack = new BCGColor(255, 255, 255);
$font = new BCGFontFile('./font/Arial.ttf', 11);
$code = new BCGcode128();
// Or another class name from the manual
$code->setScale(2);
// Resolution
$code->setThickness(30);
// Thickness
$code->setForegroundColor($colorFront);
// Color of bars
示例6: mysql_query
<th>Chance</th>
</tr>
</thead>
';
$result = mysql_query("SELECT * FROM `spawnentry` WHERE `spawngroupID` = " . $spawn_group_id);
while ($row = mysql_fetch_array($result)) {
$Content .= '
<tr db_table="spawnentry" db_key="spawngroupID,npcID" db_key_val="' . $row['spawngroupID'] . ',' . $row['npcID'] . '">
<td style="background-color:orange" nonedit="1">' . $row['npcID'] . '</td>
<td style="background-color:yellow" nonedit="1">' . $row['spawngroupID'] . '</td>
<td field_name="chance">' . $row['chance'] . '</td>
</tr>';
}
$Content .= '</table>';
$Content .= '<script type="text/javascript" src="modules/NPC/ajax/spawn_editor.js"></script>';
echo Modal('Spawn Editor', $Content, '');
}
/* Handle field updates from spawn editor tables */
if (isset($_GET['do_spawn_edit_update'])) {
$table_name = mysql_real_escape_string($_GET['do_spawn_edit_update']);
$field = mysql_real_escape_string($_GET['field']);
$value = mysql_real_escape_string($_GET['value']);
$db_key = $_GET['db_key'];
$db_key_val = $_GET['db_key_val'];
if (preg_match('/,/i', $_GET['db_key'])) {
$db_key = explode(",", $db_key);
$db_key_val = explode(",", $db_key_val);
$filter = $db_key[0] . " = " . $db_key_val[0] . " AND " . $db_key[1] . " = " . $db_key_val[1];
} else {
$filter = $db_key . " = " . $db_key_val;
}
示例7: toLogin
<?php
require_once 'support/config.php';
if (!isLoggedIn()) {
toLogin();
die;
}
if (empty($_GET['id'])) {
Modal("No Account Selected");
redirect("all_clients.php");
die;
} else {
$account = $con->myQuery("SELECT account_name,industry,address,account_handler,account_status FROM qry_accounts WHERE id=?", array($_GET['id']))->fetch(PDO::FETCH_ASSOC);
if (empty($account)) {
Modal("Invalid Account Selected");
redirect("all_clients.php");
die;
}
}
makeHead();
?>
<div id='wrapper'>
<?php
require_once 'template/navbar.php';
?>
</div>
<div id="page-wrapper">
<div class='row'>
<div class='col-md-12'>
<h1 class="page-header">Posts</h1>
示例8: toLogin
<?php
require_once 'support/config.php';
if (!isLoggedIn()) {
toLogin();
die;
}
if (!AllowUser(array(1))) {
redirect("index.php");
}
if (!empty($_GET['id'])) {
$asset = $con->myQuery("SELECT id,user_type_id,first_name,middle_name,last_name,username,password,email,contact_no,employee_no,location_id,title,department_id from users WHERE id=?", array($_GET['id']))->fetch(PDO::FETCH_ASSOC);
if (empty($asset)) {
//Alert("Invalid consumables selected.");
Modal("Invalid user selected");
redirect("users.php");
die;
}
}
makeHead("Product statuses");
?>
<div id='wrapper'>
<?php
require_once 'template/navbar.php';
?>
</div>
<div id="page-wrapper">
<div class="row">
<div class="col-lg-12">
<h1 class="page-header">Product Statuses form</h1>
</div>
示例9: mysql_query
$result = mysql_query("DELETE FROM `lootdrop_entries` WHERE `lootdrop_id` = " . $loot_drop . " AND `item_id` = " . $item_id);
if (!$result) {
echo mysql_error();
}
}
/* Loot Table :: Delete Item :: Confirmation Window */
if ($_GET['do_loot_table_delete']) {
$loot_table = $_GET['do_loot_table_delete'];
$loot_drop_id = $_GET['loot_drop_id'];
$Content .= '
<center>
<button type="button" class="btn btn-default btn-sm red btn-xs" onclick="do_loot_table_delete_confirmed(' . $loot_table . ', ' . $loot_drop_id . ')">
<i class="fa fa-times"></i> Confirm Delete
</button>
</center>';
echo Modal('Loot Table Loot Drop Removal Confirm', $Content, '');
}
/* Loot Table :: Delete Item from DB */
if ($_GET['do_loot_table_delete_confirmed']) {
$loot_table = $_GET['do_loot_table_delete_confirmed'];
$loot_drop_id = $_GET['loot_drop_id'];
$result = mysql_query("DELETE FROM `loottable_entries` WHERE `loottable_id` = " . $loot_table . " AND `lootdrop_id` = " . $loot_drop_id);
if (!$result) {
echo mysql_error();
}
}
/* Loot Table :: Save Loot Table Field Values */
if (isset($_GET['update_loottable'])) {
$loot_table = $_GET['update_loottable'];
$loot_drop = $_GET['loot_drop'];
$db_field = $_GET['field'];
示例10: Modal
}
}
}
}
}
}
}
}
}
}
}
}
$Content .= '</table>';
// $Content .= '<table class="table-bordered table-striped table-condensed flip-content" style="width:100%">';
$Content .= '<center><small>Hover over each input to see the descriptions for each special ability </small></center>';
$Content .= $top_content;
// $Content .= '</table>';
$Content .= '<br>';
$Content .= '<table class="table-bordered table-striped table-condensed flip-content" style="width:100%">';
$Content .= $bottom_content;
$Content .= '</table>';
$Content .= '<br>';
$Content .= '<table style="width:100%">';
$Content .= '<tr><td><input type="text" class="form-control m-wrap span6" value="' . $db_val . '" id="special_attacks_result" style="width:100% !important;"></td></tr>';
$Content .= '<tr><td> </td></tr>';
$Content .= '<tr><td><a href="javascript:;" class="button btn blue" onclick="update_npc_field(' . $npc_id . ', \'' . $db_field . '\', $(\'#special_attacks_result\').val())"><i class="icon-save"></i>Save to NPC ID:' . $npc_id . '</a></td></tr>';
$Content .= '</table>';
$Content .= '</div>';
echo '<script type="text/javascript" src="modules/NPC/ajax/npc_special_attacks.js"></script>';
echo Modal('Special Abilites Editor', $Content, '');
}