67
L I S T I N G P R O G R A M
Universitas Sumatera Utara
1
1.
Koneksi Database
2.
Index.php <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
Shop Online <script src="js/jquery-1.8.2.min.js" type="text/javascript"> <script src="js/jquery.carouFredSel-6.2.0-packed.js" type="text/javascript"> <script src="js/selectdesa.js"> <script type="text/javascript"> $(function() { var $imgs = $('#images .carousel'), $capt = $('#captions .carousel'), $timr = $('#timer'); $imgs.carouFredSel({ circular: false, scroll: { easing: 'quadratic', duration: 2, timeoutDuration: 3000, onBefore: function( data ) {
Universitas Sumatera Utara
2
$capt.trigger( 'slideTo', [ '.' + data.items.visible.first().attr( 'alt' ) ] ); $timr.stop().animate({ opacity: 0 }, data.scroll.duration); }, onAfter: function() { $timr.stop().animate({ opacity: 1 }, 150); } }, auto: { progress: '#timer' }, pagination: { container: '.pager', anchorBuilder: function( i ) { return '
'; } } }); $capt.carouFredSel({ circular: false, auto: false, scroll: { easing: 'quadratic', duration: 2 } }); }); <script src="js/jquery-1.8.2.min.js" type="text/javascript"> <script src="js/jquery.carouFredSel-6.1.0-packed.js" type="text/javascript"> <script type="text/javascript"> $(function() { $('#carousel').carouFredSel({ width: 960, items: 4, scroll: 1, auto: { duration: 1250, timeoutDuration: 2500 }, prev: '#next', next: '#prev', pagination: '#pager' });
Universitas Sumatera Utara
3
});
Universitas Sumatera Utara
4
if ($_REQUEST['p'] != "") { include $_REQUEST['p']; } else include "center.php" ?>
3.
Center
Top Brands Dekstop
Universitas Sumatera Utara
6
4.
Item
Universitas Sumatera Utara
9
"; while ($row=mysql_fetch_array($sql)){ if($i>=$kolom){ echo " "; $i=0; } $i++; ?> &nama_item="> ' border='0' width='220' height='150'>
,00- ";?> "; ?>
Universitas Sumatera Utara
10
5.
Item Detail ,00- '3'){ echo "Stock : ada";} else{ echo "Stock : terbatas";}?>
Universitas Sumatera Utara
12
' width="400" height="300">
6.
Register <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> Untitled Document
Universitas Sumatera Utara
13
Top Brands
Universitas Sumatera Utara
14
Universitas Sumatera Utara
15
7.
Pemrosesan Register <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> Untitled Document include "includes/koneksi.php"; $fnama=$_POST['fnama']; $lnama=$_REQUEST['lnama']; $unama=$_REQUEST['unama']; $password=$_REQUEST['password']; if(isset($_POST[submit])) { $sql=mysql_query("INSERT INTO users (fnama,lnama,unama,password,status) values ('$fnama','$lnama','$unama','$password','member')", $koneksi) or die (mysql_error()); ?> <script language="javascript"> alert('Proses Berhasil') window.location="login.php"; } else { ?> <script language="javascript"> alert('Masukkan Data Anda dengan benar') window.location="index.php?p=register.php"; } ?>
Universitas Sumatera Utara
16
8.
Login Form Login
Universitas Sumatera Utara
17
9.
Map <meta charset="utf-8"> Marking Satu Lokasi <script type="text/javascript" src="http://maps.google.com/maps/api/js?sensor=false"> <style> html, body { font-family: Verdana, Geneva, Arial, Helvetica, sans-serif; font-size: medium; } #map { width: 500px; height: 400px; border: 1px solid black; } <script type="text/javascript"> (function() { window.onload = function() { var options = { zoom: 12, center: new google.maps.LatLng(3.561063,98.655295), mapTypeId: google.maps.MapTypeId.ROADMAP }; var map = new google.maps.Map(document.getElementById('map'), options); var marker = new google.maps.Marker({ position: new google.maps.LatLng(3.561063,98.655295), map: map, title: 'Klik Saya' }); var infowindow = new google.maps.InfoWindow({ content: 'Ini adalah Tugu Jogja' }); google.maps.event.addListener(marker, 'click', function(){ infowindow.open(map, marker); }); }; })(); Marking Satu Lokasi