initital comm

parent 2f43bf4a
<?php include_once 'kepala.php';
$result = mysqli_query($ok->conn(),'Select * from toga');
$result11 = mysqli_query($ok->conn(),'Select * from toga');
?>
<html>
<head>
<script type="text/javascript" src="https://www.gstatic.com/charts/loader.js"></script>
<script type="text/javascript">
// Load Charts and the corechart package.
google.charts.load('current', {'packages':['corechart']});
// Draw the pie chart for Sarah's pizza when Charts is loaded.
google.charts.setOnLoadCallback(drawSarahChart);
// Draw the pie chart for the Anthony's pizza when Charts is loaded.
google.charts.setOnLoadCallback(drawAnthonyChart);
// Callback that draws the pie chart for Sarah's pizza.
function drawSarahChart() {
// Create the data table for Sarah's pizza.
var data = new google.visualization.DataTable();
data.addColumn('string', 'Topping');
data.addColumn('number', 'Slices');
data.addRows([
<?php
while($user_data = mysqli_fetch_array($result)){
extract($user_data);
$ww =$ok->countbeibe($user_data['id_toga']);
echo "['{$nama_toga}',".$ww."],";
}
?>
]);
// Set options for Sarah's pie chart.
var options = {title:'Pie Charts Beibe',
width:530,
height:300};
// Instantiate and draw the chart for Sarah's pizza.
var chart = new google.visualization.PieChart(document.getElementById('Sarah_chart_div'));
chart.draw(data, options);
}
// Callback that draws the pie chart for Anthony's pizza.
function drawAnthonyChart() {
// Create the data table for Anthony's pizza.
var data = new google.visualization.DataTable();
data.addColumn('string', 'Topping');
data.addColumn('number', 'Slices');
data.addRows([
<?php
while($user_data = mysqli_fetch_array($result11)){
extract($user_data);
$ww =$ok->count($user_data['id_toga']);
echo "['{$nama_toga}',".$ww."],";
}
?>
]);
// Set options for Anthony's pie chart.
var options = {title:'Pie Charts Marga',
width:530,
height:300};
// Instantiate and draw the chart for Anthony's pizza.
var chart = new google.visualization.PieChart(document.getElementById('Anthony_chart_div'));
chart.draw(data, options);
}
</script>
</head>
<body>
<?php include_once 'kepala.php'; ?>
<?php include_once 'kiri.php'; ?>
<!-- Right Panel -->
<div id="right-panel" class="right-panel">
<!--Table and divs that hold the pie charts-->
<table class="columns">
<tr>
<td><div id="Sarah_chart_div" style="border: 1px solid #ccc"></div></td>
<td><div id="Anthony_chart_div" style="border: 1px solid #ccc"></div></td>
</tr>
</table>
</div>
</body>
<script src="vendors/jquery/dist/jquery.min.js"></script>
<script src="vendors/popper.js/dist/umd/popper.min.js"></script>
<script src="vendors/bootstrap/dist/js/bootstrap.min.js"></script>
<script src="assets/js/main.js"></script>
<script src="vendors/chart.js/dist/Chart.bundle.min.js"></script>
<script src="assets/js/dashboard.js"></script>
<script src="assets/js/widgets.js"></script>
<script src="vendors/jqvmap/dist/jquery.vmap.min.js"></script>
<script src="vendors/jqvmap/examples/js/jquery.vmap.sampledata.js"></script>
<script src="vendors/jqvmap/dist/maps/jquery.vmap.world.js"></script>
</html>
\ No newline at end of file
......@@ -284,7 +284,7 @@
type: 'pie',
data: {
datasets: [ {
data: [ 45, 25, 20, 10 ],
data: [ 450, 25, 20, 10 ],
backgroundColor: [
"rgba(0, 123, 255,0.9)",
"rgba(0, 123, 255,0.7)",
......
<?php include_once 'kepala.php';
$result = mysqli_query($ok->conn(),'Select * from toga');
?>
<html>
<head>
<script type="text/javascript" src="https://www.gstatic.com/charts/loader.js"></script>
<script type="text/javascript">
google.charts.load('current', {'packages':['corechart']});
</script>
<script type="text/javascript">
google.charts.load("current", {packages:["corechart"]});
google.charts.setOnLoadCallback(drawChart);
function drawChart() {
var data = google.visualization.arrayToDataTable([
['Marga', 'Jumlah'],
<?php
while($user_data = mysqli_fetch_array($result)){
extract($user_data);
$ww =$ok->count($user_data['id_toga']);
echo "['{$nama_toga}',".$ww."],";
}
?>
]);
var options = {
title: 'My Daily Activities',
is3D: true,
};
var chart = new google.visualization.PieChart(document.getElementById('piechart_3d'));
chart.draw(data, options);
}
</script>
</head>
<body>
<div id="piechart_3d" style="width: 900px; height: 500px;"></div>
</body>
</html>
\ No newline at end of file
......@@ -67,3 +67,15 @@
</div>
</div>
</div>
<script src="vendors/jquery/dist/jquery.min.js"></script>
<script src="vendors/popper.js/dist/umd/popper.min.js"></script>
<script src="vendors/bootstrap/dist/js/bootstrap.min.js"></script>
<script src="assets/js/main.js"></script>
<script src="vendors/chart.js/dist/Chart.bundle.min.js"></script>
<script src="assets/js/dashboard.js"></script>
<script src="assets/js/widgets.js"></script>
<script src="vendors/jqvmap/dist/jquery.vmap.min.js"></script>
<script src="vendors/jqvmap/examples/js/jquery.vmap.sampledata.js"></script>
<script src="vendors/jqvmap/dist/maps/jquery.vmap.world.js"></script>
......@@ -17,10 +17,7 @@
<!-- /.menu-title -->
<li class="">
<a href="inputMarga.php"> <i class="menu-icon fa fa-dashboard"></i>Input Marga & Toga </a>
</li>
<li class="">
<a href="TampilMarga.php"> <i class="menu-icon fa fa-dashboard"></i>Edit daftar Toga </a>
</li>
<li class="menu-item-has-children dropdown">
<a href="#" class="dropdown-toggle" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false"> <i class="menu-icon fa fa-laptop"></i>Edit daftar Marga</a>
<ul class="sub-menu children dropdown-menu">
......@@ -32,57 +29,21 @@
</ul>
</li>
<li class="menu-item-has-children dropdown">
<a href="#" class="dropdown-toggle" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false"> <i class="menu-icon fa fa-table"></i>Tables</a>
<a href="#" class="dropdown-toggle" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false"> <i class="menu-icon fa fa-laptop"></i>Tampilkan data User</a>
<ul class="sub-menu children dropdown-menu">
<li><i class="fa fa-table"></i><a href="tables-basic.html">Basic Table</a></li>
<li><i class="fa fa-table"></i><a href="tables-data.html">Data Table</a></li>
<?php
$result = mysqli_query($ok->conn(),'Select * from toga');
while($user_data = mysqli_fetch_array($result)){ ?>
<li><i class="fa fa-puzzle-piece"></i><a href="Tampilmarga.php?<?php echo "marga="; echo $user_data['id_toga']; ?>"><?php echo $user_data['nama_toga']; ?></a></li>
<?php } ?>
</ul>
</li>
<li class="menu-item-has-children dropdown">
<a href="#" class="dropdown-toggle" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false"> <i class="menu-icon fa fa-th"></i>Forms</a>
<ul class="sub-menu children dropdown-menu">
<li><i class="menu-icon fa fa-th"></i><a href="forms-basic.html">Basic Form</a></li>
<li><i class="menu-icon fa fa-th"></i><a href="forms-advanced.html">Advanced Form</a></li>
</ul>
<li class="">
<a href="TampilGraphic.php"> <i class="menu-icon fa fa-dashboard"></i>Tampilkan Grafik</a>
</li>
<h3 class="menu-title">Icons</h3><!-- /.menu-title -->
<li class="menu-item-has-children dropdown">
<a href="#" class="dropdown-toggle" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false"> <i class="menu-icon fa fa-tasks"></i>Icons</a>
<ul class="sub-menu children dropdown-menu">
<li><i class="menu-icon fa fa-fort-awesome"></i><a href="font-fontawesome.html">Font Awesome</a></li>
<li><i class="menu-icon ti-themify-logo"></i><a href="font-themify.html">Themefy Icons</a></li>
</ul>
</li>
<li>
<a href="widgets.html"> <i class="menu-icon ti-email"></i>Widgets </a>
</li>
<li class="menu-item-has-children dropdown">
<a href="#" class="dropdown-toggle" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false"> <i class="menu-icon fa fa-bar-chart"></i>Charts</a>
<ul class="sub-menu children dropdown-menu">
<li><i class="menu-icon fa fa-line-chart"></i><a href="charts-chartjs.html">Chart JS</a></li>
<li><i class="menu-icon fa fa-area-chart"></i><a href="charts-flot.html">Flot Chart</a></li>
<li><i class="menu-icon fa fa-pie-chart"></i><a href="charts-peity.html">Peity Chart</a></li>
</ul>
</li>
<li class="menu-item-has-children dropdown">
<a href="#" class="dropdown-toggle" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false"> <i class="menu-icon fa fa-area-chart"></i>Maps</a>
<ul class="sub-menu children dropdown-menu">
<li><i class="menu-icon fa fa-map-o"></i><a href="maps-gmap.html">Google Maps</a></li>
<li><i class="menu-icon fa fa-street-view"></i><a href="maps-vector.html">Vector Maps</a></li>
</ul>
</li>
<h3 class="menu-title">Extras</h3><!-- /.menu-title -->
<li class="menu-item-has-children dropdown">
<a href="#" class="dropdown-toggle" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false"> <i class="menu-icon fa fa-glass"></i>Pages</a>
<ul class="sub-menu children dropdown-menu">
<li><i class="menu-icon fa fa-sign-in"></i><a href="page-login.html">Login</a></li>
<li><i class="menu-icon fa fa-sign-in"></i><a href="page-register.html">Register</a></li>
<li><i class="menu-icon fa fa-paper-plane"></i><a href="pages-forget.html">Forget Pass</a></li>
</ul>
</li>
</ul>
</div><!-- /.navbar-collapse -->
</nav>
......
google.charts.load("current", {packages:["corechart"]});
google.charts.setOnLoadCallback(drawChart);
function drawChart() {
var data = google.visualization.arrayToDataTable([
['Marga', 'Jumlah'],
<?php
while($user_data = mysqli_fetch_array($result)){
extract($user_data);
$ww =$ok->count($user_data['id_toga']);
echo "['{$nama_toga}',".$ww."],";
}
?>
// ['Work', 11],
// ['Eat', 2],
// ['Commute', 2],
// ['Watch TV', 2],
// ['Sleep', 7]
]);
var options = {
title: 'My Daily Activities',
is3D: true,
};
var chart = new google.visualization.PieChart(document.getElementById('piechart_3d'));
chart.draw(data, options);
}
\ No newline at end of file
<?php include_once 'kepala.php'; ?>
<?php include_once 'kiri.php'; ?>
<div id="right-panel" class="right-panel">
<div class="breadcrumbs">
<div class="col-sm-4">
<div class="page-header float-left">
<div class="page-title">
<h1></h1>
</div>
</div>
</div>
<div class="col-sm-8">
<div class="page-header float-right">
<div class="page-title">
<ol class="breadcrumb text-right">
<li class="active"></li>
</ol>
</div>
</div>
</div>
</div>
<div class="breadcrumbs">
<div class="col-sm-4">
<div class="page-header float-left">
<div class="page-title">
<h1>Daftar Toga</h1>
</div>
</div>
</div>
</div>
<div class="col-sm-12 col-lg-12">
<table id="dtBasicExample" class="table table-striped table-bordered table-sm" cellspacing="0" width="100%">
<thead>
<tr>
<th class="th-sm">No
</th>
<th class="th-sm">Nama Toga
</th>
<th class="th-sm">Action
</th>
</tr>
</thead>
<tbody>
<?php
$a =1;
$ok = new data();
$result = mysqli_query($ok->conn(),'Select * from toga');
while($user_data = mysqli_fetch_array($result)){ ?>
<?php include_once 'kepala.php'; ?>
<?php include_once 'kiri.php'; ?>
<!-- Right Panel -->
<div id="right-panel" class="right-panel">
<?php $coneksi = new SudahLogin(); ?>
<?php if(!isset($_GET['marga'])) header('Location: index.php'); $id = $_GET['marga']?>
<?php include_once 'header.php'; ?>
<h1> <?php echo "Toga ".$coneksi->ambilToga($_GET['marga']); ?></h1>
<table class="w3-table w3-striped">
<tr>
<td><?php echo $a; ?></td>
<td> <?php echo $user_data['nama_toga']; $a++; ?></td>
<td> <a href="edit_toga.php?<?php echo md5('edit')."=".$user_data['id_toga'] ?>">Hapus</a> | <a href="hapus.php?id=<?php echo $user_data['id_toga'] ?>">Edit</a></td>
<th>No </th>
<th>Nama</th>
<th>Marga</th>
</tr>
<?php };?>
</tbody>
<tfoot>
<tr><th>No</th>
<th>Nama Toga
</th>
</tr>
</tfoot>
</table>
</div>
<br>
</div>
<?php include_once('kaki.php') ?>
<?php
$ok12 =1;
$result = mysqli_query($ok->conn(),"Select data_user.nama as ok, marga.marga as mrg from data_user inner join marga where marga.toga = '$id' and marga.id_marga = data_user.marga");
while($user_data =$result->fetch_assoc()){
echo "<tr>";
echo "<td>".$ok12."</td>";
echo "<td>".$user_data['ok']; echo " </td>";
echo "<td>".$user_data['mrg']; echo " </td>";
echo "<tr>";
$ok12++;
}
?>
</table>
</div>
<script src="vendors/jquery/dist/jquery.min.js"></script>
<script src="vendors/popper.js/dist/umd/popper.min.js"></script>
<script src="vendors/bootstrap/dist/js/bootstrap.min.js"></script>
<script src="assets/js/main.js"></script>
<script src="vendors/chart.js/dist/Chart.bundle.min.js"></script>
<script src="assets/js/dashboard.js"></script>
<script src="assets/js/widgets.js"></script>
<script src="vendors/jqvmap/dist/jquery.vmap.min.js"></script>
<script src="vendors/jqvmap/examples/js/jquery.vmap.sampledata.js"></script>
<script src="vendors/jqvmap/dist/maps/jquery.vmap.world.js"></script>
<script>
(function($) {
"use strict";
jQuery('#vmap').vectorMap({
map: 'world_en',
backgroundColor: null,
color: '#ffffff',
hoverOpacity: 0.7,
selectedColor: '#1de9b6',
enableZoom: true,
showTooltip: true,
values: sample_data,
scaleColors: ['#1de9b6', '#03a9f5'],
normalizeFunction: 'polynomial'
});
})(jQuery);
</script>
</body>
</html>
<html>
<head>
<script type="text/javascript" src="https://www.gstatic.com/charts/loader.js"></script>
<script type="text/javascript">
google.charts.load('current', {'packages':['corechart']});
google.charts.setOnLoadCallback(drawChart);
function drawChart() {
var data = google.visualization.arrayToDataTable([
['Task', 'Hours per Day'],
['Work', 11],
['Eat', 2],
['Commute', 2],
['Watch TV', 2],
['Sleep', 7]
]);
var options = {
title: 'My Daily Activities'
};
var chart = new google.visualization.PieChart(document.getElementById('piechart'));
chart.draw(data, options);
}
</script>
</head>
<body>
<div id="piechart" style="width: 900px; height: 500px;"></div>
</body>
</html>
<?php include_once 'kepala.php';
$result = mysqli_query($ok->conn(),'Select * from toga');
$result11 = mysqli_query($ok->conn(),'Select * from toga');
?>
<html>
<head>
<script type="text/javascript" src="https://www.gstatic.com/charts/loader.js"></script>
<script type="text/javascript">
// Load Charts and the corechart package.
google.charts.load('current', {'packages':['corechart']});
// Draw the pie chart for Sarah's pizza when Charts is loaded.
google.charts.setOnLoadCallback(drawSarahChart);
// Draw the pie chart for the Anthony's pizza when Charts is loaded.
google.charts.setOnLoadCallback(drawAnthonyChart);
// Callback that draws the pie chart for Sarah's pizza.
function drawSarahChart() {
// Create the data table for Sarah's pizza.
var data = new google.visualization.DataTable();
data.addColumn('string', 'Topping');
data.addColumn('number', 'Slices');
data.addRows([
<?php
while($user_data = mysqli_fetch_array($result)){
extract($user_data);
$ww =$ok->countbeibe($user_data['id_toga']);
echo "['{$nama_toga}',".$ww."],";
}
?>
]);
// Set options for Sarah's pie chart.
var options = {title:'How Much Pizza Sarah Ate Last Night',
width:400,
height:300};
// Instantiate and draw the chart for Sarah's pizza.
var chart = new google.visualization.PieChart(document.getElementById('Sarah_chart_div'));
chart.draw(data, options);
}
// Callback that draws the pie chart for Anthony's pizza.
function drawAnthonyChart() {
// Create the data table for Anthony's pizza.
var data = new google.visualization.DataTable();
data.addColumn('string', 'Topping');
data.addColumn('number', 'Slices');
data.addRows([
<?php
while($user_data = mysqli_fetch_array($result11)){
extract($user_data);
$ww =$ok->count($user_data['id_toga']);
echo "['{$nama_toga}',".$ww."],";
}
?>
]);
// Set options for Anthony's pie chart.
var options = {title:'How Much Pizza Anthony Ate Last Night',
width:400,
height:300};
// Instantiate and draw the chart for Anthony's pizza.
var chart = new google.visualization.PieChart(document.getElementById('Anthony_chart_div'));
chart.draw(data, options);
}
</script>
</head>
<body>
<!--Table and divs that hold the pie charts-->
<table class="columns">
<tr>
<td><div id="Sarah_chart_div" style="border: 1px solid #ccc"></div></td>
<td><div id="Anthony_chart_div" style="border: 1px solid #ccc"></div></td>
</tr>
</table>
</body>
</html>
\ No newline at end of file
<?php include_once 'first.php'; ?>
<?php $tutur = new tutur(); ?>
<?php if(!isset($_GET['nama'])){
header('Location: pencarian.php');
} ?>
<?php $id = $_SESSION['id']; ?>
<!DOCTYPE html>
<html lang="en">
<head>
<title>Arcade - Architecture</title>
<meta charset="UTF-8">
<meta name="description" content="Arcade - Architecture Template">
<meta name="keywords" content="arcade, architecture, onepage, creative, html">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<link href="img/favicon.ico" rel="shortcut icon"/>
<link href="https://fonts.googleapis.com/css?family=Roboto:300,400,500,700" rel="stylesheet">
<link rel="stylesheet" href="https://www.w3schools.com/w3css/4/w3.css">
<link rel="stylesheet" href="css/bootstrap.min.css"/>
<link rel="stylesheet" href="css/font-awesome.min.css"/>
<link rel="stylesheet" href="css/animate.css"/>
<link rel="stylesheet" href="css/owl.carousel.css"/>
<link rel="stylesheet" href="css/style.css"/>
</head>
<body>
<div id="preloder">
<div class="loader"></div>
</div>
<?php $ok->header(); ?>
<section class="hero-section">
<div class="left-bar">
<div class="left-bar-content">
<div class="social-links">
<a href="#"><i class="fa fa-pinterest"></i></a>
<a href="#"><i class="fa fa-linkedin"></i></a>
<a href="#"><i class="fa fa-instagram"></i></a>
<a href="#"><i class="fa fa-facebook"></i></a>
<a href="#"><i class="fa fa-twitter"></i></a>
</div>
</div>
</div>
<!-- hero slider area -->
<div class="hero-slider">
<div class="hero-slide-item set-bg" data-setbg="gambar/danau.jpg">
<div class="slide-inner">
<div class="slide-content">
<h2>Partutur.on</h2>
</div>
</div>
</div>
<div class="hero-slide-item set-bg" data-setbg="gambar/danau2.jpg">
<div class="slide-inner">
<div class="slide-content">
<h2>Partutur.on</h2>
</div>
</div>
</div>
</div>
<div class="slide-num-holder" id="snh-1"></div>
<div class="hero-right-text">Partutur</div>
</section>
<!-- Hero section end -->
<!-- Intro section start -->
<div class="projects-section pb50">
<div class="container">
<h1><?php echo $_GET['nama'] ?></h1>
<?php $Ok = new tutur();
$kelamin = $Ok->cari_kelamin($id);
$toga = $Ok->dapat_toga($id);
$togamamak = $Ok->dapat_toga_mamak($id);
if(!strcmp($_GET['nama'], 'ito')){
?>
<table class="w3-table w3-striped">
<tr>
<th>Nama</th>
<th>Marga / Boru</th>
<th>Beibe</th>
</tr>
<?php
$sql = "SELECT data_user.nama as ok, marga.marga as magg , data_user.mamak as mams FROM data_user inner join marga where marga.toga = '$toga' and data_user.marga = marga.id_marga and data_user.Jenis_kelamin !='$kelamin' or marga.toga = '$togamamak' and data_user.mamak = marga.id_marga and data_user.Jenis_kelamin !='$kelamin' ";
$check = $Ok->conn()->query($sql);
while($user_data =$check->fetch_assoc()){
$sq = $user_data['mams'];
$sqq = "SELECT marga as mr from marga where id_marga = '$sq'";
$check1 = $Ok->conn()->query($sqq);
$row =$check1->fetch_assoc();
echo "<tr><td>".$user_data['ok']."</td><td>".$user_data['magg']."</td><td>".$row['mr']."</tr>";
}
}
if(!strcmp($_GET['nama'], 'pariban')){
?>
<?php if($kelamin==1){
$sql = "SELECT data_user.nama as ok, marga.marga as magg , data_user.mamak as mams FROM data_user inner join marga where marga.toga = '$togamamak' and data_user.marga = marga.id_marga and data_user.Jenis_kelamin !='$kelamin' ";
}else{
$sql = "SELECT data_user.nama as ok, marga.marga as magg , data_user.marga as mams FROM data_user inner join marga where marga.toga = '$toga' and data_user.mamak = marga.id_marga and data_user.Jenis_kelamin !='$kelamin' ";
}
?>
<table class="w3-table w3-striped">
<tr>
<th>Nama</th>
<th>Marga / Boru</th>
<th>Beibe</th>
</tr>
<?php
// $sql = "SELECT data_user.nama as ok, marga.marga as magg , data_user.mamak as mams FROM data_user inner join marga where marga.toga = '$togamamak' and data_user.marga = marga.id_marga and data_user.Jenis_kelamin !='$kelamin' ";
$check = $Ok->conn()->query($sql);
while($user_data =$check->fetch_assoc()){
$sq = $user_data['mams'];
$sqq = "SELECT marga as mr from marga where id_marga = '$sq'";
$check1 = $Ok->conn()->query($sqq);
$row =$check1->fetch_assoc();
if($kelamin == 2){
echo "<tr><td>".$user_data['ok']."</td><td>".$row['mr']."</td><td>".$user_data['magg']."</tr>";
}else{
echo "<tr><td>".$user_data['ok']."</td><td>".$user_data['magg']."</td><td>".$row['mr']."</tr>";
}
}
}
if(!strcmp($_GET['nama'], 'appara')){
?>
<table class="w3-table w3-striped">
<tr>
<th>Nama</th>
<th>Marga / Boru</th>
<th>Beibe</th>
</tr>
<?php
$sql = "SELECT data_user.nama as ok, marga.marga as magg , data_user.mamak as mams FROM data_user inner join marga where marga.toga = '$toga' and data_user.marga = marga.id_marga and data_user.Jenis_kelamin ='$kelamin' and data_user.id_nama != '$id' ";
$check = $Ok->conn()->query($sql);
while($user_data =$check->fetch_assoc()){
$sq = $user_data['mams'];
$sqq = "SELECT marga as mr from marga where id_marga = '$sq'";
$check1 = $Ok->conn()->query($sqq);
$row =$check1->fetch_assoc();
echo "<tr><td>".$user_data['ok']."</td><td>".$user_data['magg']."</td><td>".$row['mr']."</tr>";
}
}
if(!strcmp($_GET['nama'], 'bere')){
?>
<table class="w3-table w3-striped">
<tr>
<th>Nama</th>
<th>Marga / Boru</th>
<th>Beibe</th>
</tr>
<?php
$sql = "SELECT data_user.nama as ok, marga.marga as magg , data_user.marga as mams FROM data_user inner join marga where marga.toga = '$toga' and data_user.mamak = marga.id_marga and data_user.Jenis_kelamin !='$kelamin' ";
$check = $Ok->conn()->query($sql);
while($user_data =$check->fetch_assoc()){
$sq = $user_data['mams'];
$sqq = "SELECT marga as mr from marga where id_marga = '$sq'";
$check1 = $Ok->conn()->query($sqq);
$row =$check1->fetch_assoc();
echo "<tr><td>".$user_data['ok']."</td><td>".$row['mr']."</td><td>".$user_data['magg']."</tr>";
}
}
if(!strcmp($_GET['nama'], 'lae')){
?>
<table class="w3-table w3-striped">
<tr>
<th>Nama</th>
<th>Marga / Boru</th>
<th>Beibe</th>
</tr>
<?php
$sql = "SELECT data_user.nama as ok, marga.marga as magg , data_user.mamak as mams FROM data_user inner join marga where marga.toga = '$togamamak' and data_user.marga = marga.id_marga and data_user.Jenis_kelamin ='$kelamin' ";
$check = $Ok->conn()->query($sql);
while($user_data =$check->fetch_assoc()){
$sq = $user_data['mams'];
$sqq = "SELECT marga as mr from marga where id_marga = '$sq'";
$check1 = $Ok->conn()->query($sqq);
$row =$check1->fetch_assoc();
echo "<tr><td>".$user_data['ok']."</td><td>".$user_data['magg']."</td><td>".$row['mr']."</tr>";
}
}
?>
</table>
</div>
</div>
<a href="cetak.php" type="submit" value="cetak">button</a>
<!-- Projects section end -->
<!-- Clients section start -->
<!-- <div class="client-section spad">
<div class="container">
<div id="client-carousel" class="client-slider">
<div class="single-brand">
<a href="#">
<img src="img/clients/1.png" alt="">
</a>
</div>
<div class="single-brand">
<a href="#">
<img src="img/clients/2.png" alt="">
</a>
</div>
<div class="single-brand">
<a href="#">
<img src="img/clients/3.png" alt="">
</a>
</div>
<div class="single-brand">
<a href="#">
<img src="img/clients/4.png" alt="">
</a>
</div>
<div class="single-brand">
<a href="#">
<img src="img/clients/5.png" alt="">
</a>
</div>
</div>
</div>
</div> -->
<!-- Clients section end -->
<!-- Footer section start -->
<footer class="footer-section" style="background-color: black;">
<!-- <div class="footer-social">
<div class="social-links">
<a href="#"><i class="fa fa-pinterest"></i></a>
<a href="#"><i class="fa fa-linkedin"></i></a>
<a href="#"><i class="fa fa-instagram"></i></a>
<a href="#"><i class="fa fa-facebook"></i></a>
<a href="#"><i class="fa fa-twitter"></i></a>
</div>
</div> -->
<!-- <div class="container">
<div class="row">
<div class="col-lg-9 offset-lg-3">
<div class="row">
<div class="col-md-4">
<div class="footer-item">
<ul>
<li><a href="#">Home</a></li>
<li><a href="#">About us</a></li>
<li><a href="#">Services</a></li>
<li><a href="#">Portfolio</a></li>
<li><a href="#">Blog</a></li>
</ul>
</div>
</div>
<div class="col-md-4">
<div class="footer-item">
<ul>
<li><a href="#">Terms & Conditions</a></li>
<li><a href="#">FAQ</a></li>
<li><a href="#">Help Desk</a></li>
<li><a href="#">Job Aplications</a></li>
<li><a href="#">Site Map</a></li>
</ul>
</div>
</div>
<div class="col-md-4">
<div class="footer-item">
<ul>
<li><a href="#">Privacy</a></li>
<li><a href="#">Contact us</a></li>
<li><a href="#">Newsletter</a></li>
<li><a href="#">Clients Testimonials</a></li>
<li><a href="#">FAQ</a></li>
</ul>
</div>
</div>
</div>
</div>
</div>
</div> -->
<!-- Link back to Colorlib can't be removed. Template is licensed under CC BY 3.0. -->
<!-- Link back to Colorlib can't be removed. Template is licensed under CC BY 3.0. -->
</footer>
<!-- Footer section end -->
<!--====== Javascripts & Jquery ======-->
<script src="js/jquery-2.1.4.min.js"></script>
<script src="js/bootstrap.min.js"></script>
<script src="js/isotope.pkgd.min.js"></script>
<script src="js/owl.carousel.min.js"></script>
<script src="js/jquery.owl-filter.js"></script>
<script src="js/magnific-popup.min.js"></script>
<script src="js/circle-progress.min.js"></script>
<script src="js/main.js"></script>
</body>
</html>
......@@ -111,71 +111,8 @@
</table>
</div>
</section>
<!-- Service section end -->
<!-- CTA section start -->
<!-- <section class="cta-section pt100 pb50">
<div class="cta-image-box"></div>
<div class="container">
<div class="row">
<div class="col-lg-7 pl-lg-0 offset-lg-5 cta-content">
<h2 class="sp-title">Dare to dream of a modern <span>home</span></h2>
<p>Pellentesque lorem dolor, malesuada eget tortor vitae, tristique lacinia lectus. Pellentesque sed accumsan risus, id aliquam nulla. Integer lorem risus, feugiat at mauris malesuada, accumsan pellentesque ipsum. Nunc dapibus, libero ut pulvinar accumsan, tortor nisl iaculis ligula. Curabitur finibus dolor vel lectus pretium interdum a eget ante. </p>
<div class="cta-icons">
<div class="cta-img-icon">
<img src="img/icon/light/1.png" alt="">
</div>
<div class="cta-img-icon">
<img src="img/icon/light/2.png" alt="">
</div>
<div class="cta-img-icon">
<img src="img/icon/color/3.png" alt="">
</div>
</div>
</div>
</div>
</div>
</section> -->
<!-- CTA section end -->
<!-- Milestones section Start -->
<!-- <section class="milestones-section spad">
<div class="container">
<div class="row">
<div class="col-lg-3 col-md-6">
<div class="milestone">
<h2>14</h2>
<p>Years <br>of <br>Experience</p>
</div>
</div>
<div class="col-lg-3 col-md-6">
<div class="milestone">
<h2>237</h2>
<p>Projects <br>Taken</p>
</div>
</div>
<div class="col-lg-3 col-md-6">
<div class="milestone">
<h2>11k</h2>
<p>Twitter <br>Followers</p>
</div>
</div>
<div class="col-lg-3 col-md-6">
<div class="milestone">
<h2>12</h2>
<p>Awards <br>Won</p>
</div>
</div>
</div>
</div>
</section> -->
<!-- Milestones section end -->
<!-- Projects section start -->
<div class="projects-section pb50">
<div class="container">
<div class="row">
......
......@@ -137,6 +137,14 @@
</table>
</form>
</div>
<form action="fungsi.php" method="post">
<td><h3>Keluhan</h3></td>
<td><h3>:</h3></td>
<input class="w3-input w3-border" type="text" name="keluhan" value="">
<button type="submit" name="button">kirim</button>
</form>
</section>
<div class="projects-section pb50">
......
<?php
session_start();
include_once 'fungsi.php';
$ok = new data();
if(isset($_GET['status'])){
$ok->logout();
}
if(!isset($_SESSION['login'])){
header('Location: login.php');
}
if(isset($_SESSION['admin'])){
header('Location: admin/admin/index.php');
}
?>
\ No newline at end of file
......@@ -82,14 +82,16 @@
$check = $this->conn()->query("SELECT * from user where username='$username'");
$d = mysqli_fetch_array($check);
$ID= $d['id'];
if(mysqli_query($this->conn(),"INSERT INTO `data_user` VALUES (NULL, '$ID', '$nama', '$notset', '$notset', '$ab', '$angkatan', '$prodi', '$ok')")){
if(!mysqli_query($this->conn(),"INSERT INTO `data_user` VALUES (NULL, '$ID', '$nama', '$notset', '$notset', '$ab', '$angkatan', '$prodi', '$ok')")){
$this->sessStart();
$_SESSION['login'] = TRUE;
$_SESSION['id'] = $ID;
header('Location: index.php');
echo "Bisa";
}
else {
header('Location: register.php');
// echo "Gabisa";
}
}
}
......@@ -127,9 +129,9 @@
}
function header(){
echo "<header class='header-area'>";
echo "<a href='home.php' class='logo-area'>";
echo "<img src='img/logo.png'>";
echo "</a>";
echo "<img src='gambar/s1.png'>";
echo "</a>";
echo "<div class='nav-switch'>";
echo " <i class='fa fa-bars'></i>";
echo " </div>";
......@@ -267,10 +269,20 @@
}
}
function count($id){
$result = mysqli_query($this->conn(),"Select count(*) as total from data_user where marga = '$id'");
$result = mysqli_query($this->conn(),"Select count(*) as total from data_user inner join marga where marga.toga = '$id' and marga.id_marga = data_user.marga");
$data= mysqli_fetch_assoc($result);
return $data['total'];
}
function countbeibe($id){
$result = mysqli_query($this->conn(),"Select count(*) as total from data_user inner join marga where marga.toga = '$id' and marga.id_marga = data_user.mamak");
$data= mysqli_fetch_assoc($result);
return $data['total'];
}
function TampilUser($id){
$result = mysqli_query($this->conn(),"Select * from data_user inner join marga where marga.toga = '$id' and marga.id_marga = data_user.marga");
$data= mysqli_fetch_assoc($result);
return $data;
}
function jk1($int,$name){
$check = $this->conn()->query("SELECT * from data_user where id_nama='$int'");
if($check){
......@@ -306,7 +318,7 @@
if($check){
$d = mysqli_fetch_array($check);
if(!empty($d[$name])){
return $d[$name];
return $d[$name];
}
else {
return 8;
......@@ -365,5 +377,64 @@
header('Location: profile.php?');
}
function ambilToga($id){
$check = $this->conn()->query("SELECT * FROM toga WHERE id_toga = '$id'");
$d = mysqli_fetch_array($check);
return $d['nama_toga'];
}
}
?>
class tutur{
var $host = "localhost";
var $uname = "root";
var $pass = "";
var $db = "pabi";
function conn(){
$conn = mysqli_connect($this->host, $this->uname, $this->pass,$this->db);
return $conn;
}
function cari_kelamin($key){
$sql = "SELECT * FROM data_user WHERE id_nama = '$key'";
$check = $this->conn()->query($sql);
$d = mysqli_fetch_array($check);
return $d['Jenis_kelamin'];
}
function dapat_toga($id){
$sql = "SELECT marga.toga as ok from marga INNER JOIN data_user where data_user.id_nama = '$id' and data_user.marga = marga.id_marga";
$check = $this->conn()->query($sql);
$d = mysqli_fetch_array($check);
return $d['ok'];
}
function dapat_toga_mamak($id){
$sql = "SELECT marga.toga as ok from marga INNER JOIN data_user where data_user.id_nama = '$id' and data_user.mamak = marga.id_marga";
$check = $this->conn()->query($sql);
$d = mysqli_fetch_array($check);
return $d['ok'];
}
function tutur1($id,$tutur){
$kelamin = cari_kelamin($id);
$toga = dapat_toga($id);
if(!strcmp($tutur ,'ito')){
$sql = "SELECT data_user.nama as ok, marga.marga as mrg from data_user inner join marga where marga.toga = '$id' and marga.id_marga = data_user.marga and data_user.Jenis_kelamin is not $kelamin";
return $sql;
}
}
}
//
// $conn = mysqli_connect("localhost","root","","pabi");
// $keluhan = $_POST["keluhan"];
// $query ="INSERT INTO keluhan (id,isi_keluhan) VALUES ('', '$keluhan')";
// if(mysqli_query($conn,$query)){
// echo 'berhasil loh kontol'
// ;
// } else {
// echo 'Data gagal disimpan'.mysqli_error($conn);
// }
?>
......@@ -16,7 +16,7 @@
<meta name="description" content="Arcade - Architecture Template">
<meta name="keywords" content="arcade, architecture, onepage, creative, html">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<link href="img/favicon.ico" rel="shortcut icon"/>
<link href="img/favicon.icon" rel="shortcut icon"/>
<link href="https://fonts.googleapis.com/css?family=Roboto:300,400,500,700" rel="stylesheet">
<link rel="stylesheet" href="css/bootstrap.min.css"/>
<link rel="stylesheet" href="css/font-awesome.min.css"/>
......@@ -32,13 +32,7 @@
<section class="hero-section">
<div class="left-bar">
<div class="left-bar-content">
<div class="social-links">
<a href="#"><i class="fa fa-pinterest"></i></a>
<a href="#"><i class="fa fa-linkedin"></i></a>
<a href="#"><i class="fa fa-instagram"></i></a>
<a href="#"><i class="fa fa-facebook"></i></a>
<a href="#"><i class="fa fa-twitter"></i></a>
</div>
</div>
</div>
<!-- hero slider area -->
......@@ -179,68 +173,6 @@ Ompu Tuan Situmorang adalah anak dan Ompunta Siraja Lontung dan Ibunya Siboru Pa
</div>
</div>
</section>
<!-- Service section end -->
<!-- CTA section start -->
<!-- <section class="cta-section pt100 pb50">
<div class="cta-image-box"></div>
<div class="container">
<div class="row">
<div class="col-lg-7 pl-lg-0 offset-lg-5 cta-content">
<h2 class="sp-title">Dare to dream of a modern <span>home</span></h2>
<p>Pellentesque lorem dolor, malesuada eget tortor vitae, tristique lacinia lectus. Pellentesque sed accumsan risus, id aliquam nulla. Integer lorem risus, feugiat at mauris malesuada, accumsan pellentesque ipsum. Nunc dapibus, libero ut pulvinar accumsan, tortor nisl iaculis ligula. Curabitur finibus dolor vel lectus pretium interdum a eget ante. </p>
<div class="cta-icons">
<div class="cta-img-icon">
<img src="img/icon/light/1.png" alt="">
</div>
<div class="cta-img-icon">
<img src="img/icon/light/2.png" alt="">
</div>
<div class="cta-img-icon">
<img src="img/icon/color/3.png" alt="">
</div>
</div>
</div>
</div>
</div>
</section> -->
<!-- CTA section end -->
<!-- Milestones section Start -->
<!-- <section class="milestones-section spad">
<div class="container">
<div class="row">
<div class="col-lg-3 col-md-6">
<div class="milestone">
<h2>14</h2>
<p>Years <br>of <br>Experience</p>
</div>
</div>
<div class="col-lg-3 col-md-6">
<div class="milestone">
<h2>237</h2>
<p>Projects <br>Taken</p>
</div>
</div>
<div class="col-lg-3 col-md-6">
<div class="milestone">
<h2>11k</h2>
<p>Twitter <br>Followers</p>
</div>
</div>
<div class="col-lg-3 col-md-6">
<div class="milestone">
<h2>12</h2>
<p>Awards <br>Won</p>
</div>
</div>
</div>
</div>
</section> -->
<!-- Milestones section end -->
<!-- Projects section start -->
......@@ -262,7 +194,7 @@ Ompu Tuan Situmorang adalah anak dan Ompunta Siraja Lontung dan Ibunya Siboru Pa
</div> -->
</div>
</div>
<div id="projects-carousel" class="projects-slider">
<div id="projects-carousel" class="projects-slider">
<div class="single-project set-bg rest" data-setbg="img/projects/1.jpg">
<div class="project-content">
<h2>Biggest <br> Restaurations</h2>
......
......@@ -7,6 +7,12 @@
$ok = new data();
$ok->login($nama,$pass);
}
if(isset($_SESSION['login'])){
header('Location: index.php');
}
if(isset($_SESSION['admin'])){
header('Location: admin/admin/index.php');
}
// $chek = new data();
// $chek->redirect();
?>
......
......@@ -5,6 +5,10 @@
if(isset($_GET['status'])){
$ok->logout();
}
$Ok = new tutur();
$id = $_SESSION['id'];
$kelamin = $Ok->cari_kelamin($id);
?>
......@@ -85,7 +89,7 @@
</div>
<h3>Ito</h3>
<p>Untuk sapaan Ito, adalah panggilan bagi laki-laki kepada perempuan dan sebaliknya. Anak perempuan dari Namboru juga dipanggil Ito. Sehari-hari kalau bertemu lawan jenis yang sebaya bisalah dipanggil Ito.</p>
<?php $ok= md5('ito') ?>
<?php $ok= 'ito'; ?>
<?php echo "<a href='cari_tutur.php?nama=".$ok." ' class='readmore'>READ MORE</a>" ?>
</div>
</div>
......@@ -98,7 +102,7 @@
</div>
<h3>Pariban</h3>
<p>Di dalam suku adat batak, pariban itu sebenarnya sepupu. Yang artinya anak laki-laki dari Namboru dan anak perempuan dari Tulang dapat dinikahkan (dipasaut dalam bahasa batak). ... Jadi, pariban merupakan sepupu yang dapat dinikahi.</p>
<?php $ok= md5('pariban') ?>
<?php $ok='pariban'; ?>
<?php echo "<a href='cari_tutur.php?nama=".$ok." ' class='readmore' >READ MORE</a>" ?>
</div>
</div>
......@@ -109,25 +113,44 @@
<img src="img/icon/dark/3.png" alt="">
</div>
</div>
<h3>Appara</h3>
<p>Appara memiliki makna dalam istilah Batak ialah ‘Dongan Tubu’, jadi kata ‘Appara/Ampara’ digunakan bagi orang Batak yang memiliki marga toga yang sama, misalnya saya memanggil appara dengan teman yang semarga dengan toga saya.</p>
<?php $ok= md5('appara') ?>
<?php
if($kelamin == 2){
echo "<h3>Appiri</h3>";
}else {
echo "<h3>Appara</h3>";
}
?>
<p><?php if($kelamin ==2) echo "Appiri"; else {
echo "Appara";
} ?> memiliki makna dalam istilah Batak ialah ‘Dongan Tubu’, jadi kata <?php if($kelamin ==2) echo "Appiri "; else {
echo "Appara ";
} ?>digunakan bagi orang Batak yang memiliki marga toga yang sama, misalnya saya memanggil appara dengan teman yang semarga dengan toga saya.</p>
<?php $ok='appara'; ?>
<?php echo "<a href='cari_tutur.php?nama=".$ok." ' class='readmore' >READ MORE</a>" ?>
</div>
</div>
<div class="col-lg-4 col-md-6">
<div class="service-box">
<div class="sb-icon">
<div class="sb-img-icon">
<img src="img/icon/dark/4.png" alt="">
</div>
</div>
<h3>Bere</h3>
<p>Dalam suku batak, bere adalah semua anak (anak laki-laki + Perempuan) dari kakak atau Anak/boru dari adik perempuan kita. Misalnya ada wanita yang ibu nya berboru sama dengan marga saya, maka saya bisa memanggilnya bere.</p>
<?php $ok= md5('bere') ?>
<?php echo "<a href='cari_tutur.php?nama=".$ok." ' class='readmore' >READ MORE</a>" ?>
</div>
</div>
</div><?php if($kelamin ==1) {
} ?>
<?php
if ($kelamin == 1) {
echo "<div class='col-lg-4 col-md-6'>";
echo "<div class='service-box'>";
echo "<div class='sb-icon'>";
echo "<div class='sb-img-icon'>";
echo "<img src='img/icon/dark/4.png' alt=''>";
echo "</div>
</div>";
echo "<h3>Bere</h3>
<p>Dalam suku batak, bere adalah semua anak (anak laki-laki + Perempuan) dari kakak atau Anak/boru dari adik perempuan kita. Misalnya ada wanita yang ibu nya berboru sama dengan marga saya, maka saya bisa memanggilnya bere.</p>
";
$ok='bere';
echo "<a href='cari_tutur.php?nama=".$ok." ' class='readmore' >READ MORE</a>";
echo "</div>
</div>";
}
?>
<div class="col-lg-4 col-md-6">
<div class="service-box">
<div class="sb-icon">
......@@ -135,9 +158,11 @@
<img src="img/icon/dark/5.png" alt="">
</div>
</div>
<h3>Lae</h3>
<h3><?php if($kelamin ==2) echo "Dae"; else {
echo "Lae";
} ?></h3>
<p>Bagi orang suku batak (Toba) khusus nya kaum pria, 'lae' dapat dipanggil bila bukan satu marga nya. Dan itu juga berlaku untuk panggilan dari saudara ipar dari pihak istri atau suami jika mempunyai saudara laki - laki</p>
<?php $ok= md5('lae') ?>
<?php $ok= 'lae'; ?>
<?php echo "<a href='cari_tutur.php?nama=".$ok." ' class='readmore' >READ MORE</a>" ?>
</div>
</div>
......
......@@ -183,14 +183,6 @@
<h1>Projects</h1>
</div>
</div>
<!-- <div class="col-lg-9">
<ul class="projects-filter-nav">
<li class="btn-filter" data-filter="*">All</li>
<li class="btn-filter" data-filter=".rest">Restaurations</li>
<li class="btn-filter" data-filter=".build">Buildings</li>
<li class="btn-filter" data-filter=".apart">Apartments</li>
</ul>
</div> -->
</div>
</div>
<div id="projects-carousel" class="projects-slider">
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment