Senin, 16 September 2013

PHP Indonesia - Facebook: [Ask] [Newbie] ini yang salah bagian mananya ya ? ...

PHP Indonesia - Facebook
PHP Indonesia is a community for everyone that loves PHP. Our focus is in the PHP world but our topics encompass the entire LAMP stack. Topics include PHP coding, to memcached handling, db optimizations, server stack, web server tuning, code deploying, hosting options and much much more. Youtube Channel : http://www.youtube.com/user/OurPHPIndonesia Twitter : @php_indonesia NOTE: Rules for Wall posting: https://www.facebook.com/groups/35688476100/doc/10151597056316101/ Daftar Keanggotaan : http://www.facebook.com/groups/35688476100/doc/10150671770741101/ 
Manage your social media

Best social media tool for image publishing to Facebook and Twitter. Look amazing and delight your followers. Get 40% off when you sign up today.
From our sponsors
[Ask] [Newbie] ini yang salah bagian mananya ya ? ...
Sep 17th 2013, 01:06, by Mahfud Yoga Nugroho

Mahfud Yoga Nugroho 1:06am Sep 17
[Ask]
[Newbie]
ini yang salah bagian mananya ya ?
thanks ^_^

<html>
<body>
<p> DAFTAR MENU : <br>
1. Bakso <br>
2. Soto <br>
3. Mie Ayam <br>
4. Rames <br>
5. Sate <p>
<form action="" method="POST">
Pilih Menu :
<input type ="text" name = "menu"> <br>
<input type ="submit" name ="Pilih" value ="Pilih">

<?php
if (isset($_POST{'Pilih'}))
$menu = $_POST{"menu"};
echo "Anda Memilih Menu Nomor $menu dengan harga ";
?>
<?php
$bakso = $_POST['1'];
$soto = $_POST['2'];
$mie = $_POST['3'];
$rames = $_POST['4'];
$sate = $_POST['5'];
$menu=$_POST{"menu"};
switch($menu)
{
case 1:
echo"Rp.7000,-";
break;
case 2:
echo "Rp.5000,-";
break;
case 3:
echo "Rp.6000,-";
break;
case 4:
echo "Rp.5000,-";
break;
case 5:
echo "Rp.8000,-";
break;
default:
echo "0";
break;
}
?> <p>
<?php
if ($menu == $bakso){
$harga = 7000;
}
if ($menu == $soto){
$harga = 5000;
}
if ($menu == $mie){
$harga = 6000;
}
if ($menu == $rames){
$harga = 4000;
}
if ($menu == $sate){
$harga = 8000;
}
?>
Jumlah Pesan :
<input type ="text" name = "pesan"> <br>
<input type ="submit" name ="Hitung" value ="Hitung"> <p>
<?php
if (isset($_POST['Hitung']))
$pesan = $_POST['pesan'];
$pesan = $menu * $pesan;
echo "Total Bayar $pesan ";
?>
</form>
</body>
</html>

You are receiving this email because you subscribed to this feed at blogtrottr.com.

If you no longer wish to receive these emails, you can unsubscribe from this feed, or manage all your subscriptions

Tidak ada komentar:

Posting Komentar