Skip to content

Instantly share code, notes, and snippets.

@izoel
Created January 2, 2013 08:08
Show Gist options
  • Save izoel/4432982 to your computer and use it in GitHub Desktop.
Save izoel/4432982 to your computer and use it in GitHub Desktop.
update php
<?php
$con=mysql_connect("localhost", "root","" )or die ("gagal koneksi ke database");
mysql_select_db("dbunion",$con);
$nowo=mysql_query("select * from tblinputmbl where nowo=");
$nmstnk=$_POST['nmstnk'];
$almt=$_POST['almt'];
$notelp1=$_POST['notelp1'];
$notelp2=$_POST['notelp2'];
$platno=$_POST['platno'];
$jenis=$_POST['jenis'];
$thn=$_POST['thn'];
$km=$_POST['km'];
$norangka=$_POST['norangka'];
$nomesin=$_POST['nomesin'];
$query=mysql_query("update tblinputmbl set nmstnk='$nmstnk',almt='$almt',notelp1='$notelp2',platno='$platno',jenis='$jenis',thn='$thn',km='$km', norangka='$norangka',nomesin='$nomesin' where nowo='$nowo'");
include "tampilkandata.php";
mysql_close($con);
?>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment