当前位置: 首页>>代码示例>>PHP>>正文


PHP Post::get_ID方法代码示例

本文整理汇总了PHP中Post::get_ID方法的典型用法代码示例。如果您正苦于以下问题:PHP Post::get_ID方法的具体用法?PHP Post::get_ID怎么用?PHP Post::get_ID使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在Post的用法示例。


在下文中一共展示了Post::get_ID方法的9个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: Post

<?php

$pesan = new Post('pesan');
$id_pesan = $pesan->get_ID();
$pesanInsert = array('id_pesan' => $id_pesan, 'nama_pesan' => $_POST['nama'], 'email_pesan' => $_POST['email'], 'isi_pesan' => $_POST['pesan']);
$pesan->insert_db('pesan', $pesanInsert);
header('location:beranda');
开发者ID:KPjogjasite,项目名称:kingpheromone,代码行数:7,代码来源:aksi_contact.php

示例2: Post

<?php

if ($_GET['act'] == 'insertnew') {
    $new_scent = new Post('scent');
    $new_scent->form_start($title = 'TAMBAH scent', $path = 'scent', $module = 'scent', $table = 'scent', $action = 'insertdb', $size = 'width_full');
    //$new_scent->text_input('Judul Informasi', 'judul_scent');
    $id_scent = $new_scent->get_ID('scent');
    ?>
	<input type='hidden' name='id' value='<?php 
    echo $id_scent;
    ?>
'>
	<?php 
    $new_scent->text_input('Nama Scent', 'judul_scent');
    $new_scent->text_area('scent', 'new');
    $new_scent->form_end();
} else {
    if ($_GET['act'] == 'edit') {
        $update_scent = new Post('scent');
        $res_update_scent = $update_scent->get_db('scent', array('id_scent' => $_GET['id']));
        $update_scent->form_start($title = 'EDIT scent', $path = 'scent', $module = 'scent', $table = 'scent', $action = 'update', $size = 'width_full');
        ?>
	<input type='hidden' name='id' value='<?php 
        echo $res_update_scent[0]['id_scent'];
        ?>
'>
	<?php 
        $update_scent->text_input('Nama scent', 'judul_scent', $res_update_scent[0]['judul_scent']);
        $update_scent->text_area('scent', 'edit', $res_update_scent[0], 'description_scent');
        $update_scent->form_end();
    } else {
开发者ID:KPjogjasite,项目名称:kingpheromone,代码行数:31,代码来源:scent.php

示例3: Post

<?php

include '../../../josys/koneksi.php';
include '../../c_post.php';
$module = $_GET['module'];
$act = $_GET['act'];
$slider = new Post('slider');
if ($module == 'slider') {
    // UPDATE DATA
    if ($act == 'update') {
        $condition = array('id_slider' => $_POST['id']);
        $p_record = array('id_slider' => $_POST['id'], 'content_slider' => $_POST['isi']);
        $slider->update_db('slider', $condition, 'id_slider', $p_record);
    }
    if ($act == 'insertdb') {
        $location = $slider->upload_img('slider', $_FILES);
        $id_slider = $slider->get_ID('slider');
        $condition = array('id_slider' => $id_slider, 'thumb_slider' => $location);
        $slider->insert_db('slider', $condition);
    }
    if ($act == 'delete') {
        $slider->delete_db('slider', $_GET['id']);
    }
}
header('location:../../media.php?module=' . $module);
开发者ID:KPjogjasite,项目名称:kingpheromone,代码行数:25,代码来源:aksi_slider.php

示例4: Post

<?php

if ($_GET['act'] == 'insertnew') {
    $new_sosmed = new Post('sosmed');
    $new_sosmed->form_start($title = 'TAMBAH sosmed', $path = 'sosmed', $module = 'sosmed', $table = 'sosmed', $action = 'insertdb', $size = 'width_full');
    //$new_sosmed->text_input('Judul Informasi', 'judul_sosmed');
    $id_sosmed = $new_sosmed->get_ID('sosmed');
    ?>
	<input type='hidden' name='id' value='<?php 
    echo $id_sosmed;
    ?>
'>
	<?php 
    $new_sosmed->text_input('Nama sosmed', 'nama_sosmed');
    $new_sosmed->text_input('Link sosmed', 'link_sosmed');
    $new_sosmed->thumbnail();
    $new_sosmed->form_end();
} else {
    if ($_GET['act'] == 'edit') {
        $update_sosmed = new Post('sosmed');
        $res_update_sosmed = $update_sosmed->get_db('sosmed', array('id_sosmed' => $_GET['id']));
        $update_scent = new Post('mm_sosmed_scent');
        $res_update_scent = $update_scent->get_db('mm_sosmed_scent', array('id_sosmed' => $_GET['id']));
        $update_category = new Post('mm_sosmed_category');
        $res_update_category = $update_category->get_db('mm_sosmed_category', array('id_sosmed' => $_GET['id']));
        $update_sosmed->form_start($title = 'EDIT sosmed', $path = 'sosmed', $module = 'sosmed', $table = 'sosmed', $action = 'update', $size = 'width_full');
        ?>
	<input type='hidden' name='id' value='<?php 
        echo $res_update_sosmed[0]['id_sosmed'];
        ?>
'>
开发者ID:KPjogjasite,项目名称:kingpheromone,代码行数:31,代码来源:sosmed.php

示例5: Post

<?php

$cart = new Post('cart');
$id_cart = $cart->get_ID();
$cartInsert = array('id_cart' => $id_cart, 'nama_cart' => $_POST['nama'], 'alamat_cart' => $_POST['alamat'], 'telp_cart' => $_POST['telp'], 'email_cart' => $_POST['email'], 'pesan_cart' => $_POST['pesan'], 'tanggal_cart' => date("Y-m-d"), 'bayar_cart' => 'belum');
$cart->insert_db('cart', $cartInsert);
$pemesanan = new Post('pemesanan');
$id_pemesanan = $pemesanan->get_ID();
foreach ($_SESSION['cart_list'] as $key => $value) {
    $pemesananInsert = array('id_pemesanan' => $id_pemesanan, 'id_product' => $value['id_product'], 'id_scent' => $value['id_scent'], 'id_cart' => $id_cart, 'jumlah_pemesanan' => $value['jumlah_pesanan']);
    $pemesanan->insert_db('pemesanan', $pemesananInsert);
}
unset($_SESSION['cart_list']);
header('location:beranda');
开发者ID:KPjogjasite,项目名称:kingpheromone,代码行数:14,代码来源:aksi_identitas.php

示例6: Post

	<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.5/css/bootstrap.min.css">

	<!-- Optional theme -->
	<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.5/css/bootstrap-theme.min.css">

	<!-- Latest compiled and minified JavaScript -->
	<script src="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.5/js/bootstrap.min.js"></script>
	<script src="https://ajax.googleapis.com/ajax/libs/jquery/1.11.3/jquery.min.js"></script>

<?php 
if ($_GET['act'] == 'insertnew') {
    $new_cart = new Post('cart');
    $new_cart->form_start($title = 'TAMBAH cart', $path = 'cart', $module = 'cart', $table = 'cart', $action = 'insertdb', $size = 'width_full');
    //$new_cart->text_input('Judul Informasi', 'judul_cart');
    $id_cart = $new_cart->get_ID('cart');
    ?>
	<input type='hidden' name='id' value='<?php 
    echo $id_cart;
    ?>
'>
	<?php 
    $new_cart->text_input('Nama cart', 'judul_cart');
    $new_cart->text_area('cart', 'new');
    $new_cart->form_end();
} else {
    if ($_GET['act'] == 'edit') {
        $cartToEdit = new Post('cart');
        $cartArray = $cartToEdit->get_db('cart', $condition = array('id_cart' => $_GET['id']));
        $pemesananToEdit = new Post('pemesanan');
        $pemesananArray = $pemesananToEdit->get_db('pemesanan', $condition = array('id_cart' => $_GET['id']));
        ?>
开发者ID:KPjogjasite,项目名称:kingpheromone,代码行数:31,代码来源:cart.php

示例7: Post

<?php

if ($_GET['act'] == 'insertnew') {
    $new_product = new Post('product');
    $new_product->form_start($title = 'TAMBAH PRODUCT', $path = 'product', $module = 'product', $table = 'product', $action = 'insertdb', $size = 'width_full');
    //$new_product->text_input('Judul Informasi', 'judul_product');
    $id_product = $new_product->get_ID('product');
    ?>
	<input type='hidden' name='id' value='<?php 
    echo $id_product;
    ?>
'>
	<?php 
    $new_product->text_input('Nama Product', 'judul_product');
    $new_product->text_input('Harga Product', 'price_product');
    ?>
	<div style="padding:20px; width: 95%; background-color: #F8F8F8; border: solid 1px #DDD; border-radius: 5px">
		<div style="">
			<h3>Select Category</h3>
		</div>
		<?php 
    if ($new_product->view_Checkbox('productcategory', array('1' => '1'), 'mm_product_category', $condition = array('id_product' => $id_product))) {
    } else {
        echo "No Category Added";
    }
    ?>
	</div>
	<?php 
    $new_product->text_area('product', 'new');
    $new_product->thumbnail();
    ?>
开发者ID:KPjogjasite,项目名称:kingpheromone,代码行数:31,代码来源:product.php

示例8: Post

<?php

if ($_GET['act'] == 'insertnew') {
    $new_productcategory = new Post('productcategory');
    $new_productcategory->form_start($title = 'TAMBAH KATEGORI', $path = 'productcategory', $module = 'productcategory', $table = 'productcategory', $action = 'insertdb', $size = 'width_full');
    //$new_productcategory->text_input('Judul Informasi', 'judul_productcategory');
    $id_productcategory = $new_productcategory->get_ID('productcategory');
    ?>
	<input type='hidden' name='id' value='<?php 
    echo $id_productcategory;
    ?>
'>
	<?php 
    $new_productcategory->text_input('Nama Kategori', 'judul_productcategory');
    $new_productcategory->text_area('productcategory', 'new');
    $new_productcategory->form_end();
} else {
    if ($_GET['act'] == 'edit') {
        $update_productcategory = new Post('productcategory');
        $res_update_productcategory = $update_productcategory->get_db('productcategory', array('id_productcategory' => $_GET['id']));
        $update_productcategory->form_start($title = 'EDIT KATEGORI', $path = 'productcategory', $module = 'productcategory', $table = 'productcategory', $action = 'update', $size = 'width_full');
        ?>
	<input type='hidden' name='id' value='<?php 
        echo $res_update_productcategory[0]['id_productcategory'];
        ?>
'>
	<?php 
        $update_productcategory->text_input('Nama Kategori', 'judul_productcategory', $res_update_productcategory[0]['judul_productcategory']);
        $update_productcategory->text_area('productcategory', 'edit', $res_update_productcategory[0], 'description_productcategory');
        $update_productcategory->form_end();
    } else {
开发者ID:KPjogjasite,项目名称:kingpheromone,代码行数:31,代码来源:productcategory.php

示例9: Post

<?php

if ($_GET['act'] == 'insertnew') {
    $new_testimoni = new Post('testimoni');
    $new_testimoni->form_start($title = 'TAMBAH TESTIMONI', $path = 'testimoni', $module = 'testimoni', $table = 'testimoni', $action = 'insertdb', $size = 'width_full');
    //$new_testimoni->text_input('Judul Informasi', 'judul_testimoni');
    $id_testimoni = $new_testimoni->get_ID('testimoni');
    ?>
	<input type='hidden' name='id' value='<?php 
    echo $id_testimoni;
    ?>
'>
	<?php 
    $new_testimoni->text_input('Nama Testimoni', 'nama_testimoni');
    $new_testimoni->text_input('Isi testimoni', 'isi_testimoni');
    $new_testimoni->thumbnail();
    $new_testimoni->form_end();
} else {
    if ($_GET['act'] == 'edit') {
        $update_testimoni = new Post('testimoni');
        $res_update_testimoni = $update_testimoni->get_db('testimoni', array('id_testimoni' => $_GET['id']));
        $update_scent = new Post('mm_testimoni_scent');
        $res_update_scent = $update_scent->get_db('mm_testimoni_scent', array('id_testimoni' => $_GET['id']));
        $update_category = new Post('mm_testimoni_category');
        $res_update_category = $update_category->get_db('mm_testimoni_category', array('id_testimoni' => $_GET['id']));
        $update_testimoni->form_start($title = 'EDIT TESTIMONI', $path = 'testimoni', $module = 'testimoni', $table = 'testimoni', $action = 'update', $size = 'width_full');
        ?>
	<input type='hidden' name='id' value='<?php 
        echo $res_update_testimoni[0]['id_testimoni'];
        ?>
'>
开发者ID:KPjogjasite,项目名称:kingpheromone,代码行数:31,代码来源:testimoni.php


注:本文中的Post::get_ID方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。