PHP MySQL Ecommerce Web Design Part 3

Postingan saya kali ini adalah membuat halaman mensClothing.php beserta semua file-file yang dibutuhkannya.

1. Buat file .PHP dengan nama mensClothing.php di D:\TUTOR WEB\RIANKLIK\
Buka Notepad++, pilih File, klik Open, cari file mensClothing.php di D:\TUTOR WEB\RIANKLIK\. Isikan sama seperti script warna biru di bawah lalu jangan lupa di-save :


<?php
session_start(); //start session first thing in script
// Connect to the mySQL database
include "phpScripts/connect_to_mysql.php";
?>

<?php
// Error Reporting
error_reporting(E_ALL);
ini_set('display_errors','1');
?>

<?php
// ------------------ ORDER BY ----------------------- //
    include_once("template_orderby.php");
// --------------------------------------------------- //
?>

<?php
$dynamicList="";
    $sql=mysql_query("SELECT*FROM clothing ORDER BY product_name asc")
    or die (mysql_error());
// ------------------ PAGINATION --------------------- //
    include_once("template_page.php");
// --------------------------------------------------- //
if(isset($orderby)){
    $sql2 = mysql_query("SELECT * FROM clothing $orderby_query $limit");
} else {
    $sql2 = mysql_query("SELECT * FROM clothing ORDER BY product_name asc $limit");
} // closing if ...
// ------------------ PAGINATION --------------------- //
    include_once("template_page2.php");
// --------------------------------------------------- //          

if (!empty($sql2)){    // tambahan untuk hilangkan error saat tabel clothing kosong
    $productCount=mysql_num_rows($sql2); // count the output amount
    if($productCount>0){
        while($row=mysql_fetch_array($sql2)){
            $id=$row["id"];
            $product_name=$row["product_name"];
            $product_price=$row["product_price"];
            $product_brand=$row["product_brand"];
            $category=$row["category"];
            $subcategory=$row["subcategory"];
            $type=$row["type"];
            $color=$row["color"];
            $size=$row["size"];
            $bahan=$row["bahan"];
            $product_details=$row["product_details"];
            $designCategory=$row["designCategory"];
            $date_added=strftime("%b %d, %y", strtotime($row["date_added"]));
           
            $sqlStock=mysql_query("SELECT*FROM clothingStock
            WHERE product_name='$product_name' LIMIT 1");
            while($row=mysql_fetch_array($sqlStock)) {
                $product_nameS=$row["product_name"];
                $colorS=$row["color"];
                $sizeS=$row["size"];
            }
// ------------------ RATING & STAR ------------------ //
            include("clothing_starRating.php");
// --------------------------------------------------- //
// --------------------------------------------------- //
            include("clothing_dynamic_list.php");
// --------------------------------------------------- //   
        } //closing while ...
    }else{
        $dynamicList="We have no product listed in our store yet";   
    } // closing if ...
} //END tambahan ...
?>

<?php
// echo certain value from array
$subClothingData = mysql_query("SELECT subClothing FROM subClothing");
$subClothing = array();
while ($row = mysql_fetch_array($subClothingData)) {
    $subClothing[] = $row['subClothing'];
}
?>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"
http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="
http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />

<title>Mens Clothing</title>
<!---------------------- LINK -------------------------->
    <?php include_once("template_links_head.php"); ?>
<!---------------------- END of LINK -------------------------->

<!---------------------- LINK FREE BEAVER SLIDER -------------------------->
    <?php include_once("template_js_beaverSlider_slideshow.php"); ?>
<!----------------------  END of LINK FREE BEAVER SLIDER -------------------------->
</head>

<body>
<div id="wrapper">
    <div id="header_wrap">
           <div id="header">
            <?php include_once("template_clothingHeader.php"); ?>
        </div> <!----closing header------>
            <?php include_once("clothing_searchWrap.php"); ?>
    </div> <!----closing header_wrap------>

    <div id="content">
        <div id="leftContentWrap">
            <div id="leftContent">
                <?php include_once("template_leftContentMens.php"); ?>
            </div> <!----closing leftContent------>
        </div> <!----closing leftContentWrap------>
       
        <div id="rightContent">
            <?php include_once("template_rightContentMensClothing.php"); ?>
        </div> <!----closing rightContent------>
    </div> <!----closing content------>
   
    <div id="footer">
        <?php include_once("template_footer.php"); ?>
    </div> <!----closing footer------>
</div> <!----closing wraper------>
    <?php include_once("template_js_body.php"); ?>

</body>
</html>


2. Buat file .PHP dengan nama template_orderby.php di D:\TUTOR WEB\RIANKLIK\
Buka Notepad++, pilih File, klik Open, cari file template_orderby.php di D:\TUTOR WEB\RIANKLIK\.
Isikan sama seperti script warna biru di bawah lalu jangan lupa di-save :

<?php
$selected = array();
if (isset($_GET["orderby"])) // pemakaian isset penting!!!
   $orderby =($_GET["orderby"]);  
if(!isset($orderby)){
   $orderby = 'date_added_desc'; }
if(isset($orderby)){
   $selected[$orderby] = 'selected'; }
if($orderby == 'date_added_desc'){
   $orderby_query = "order by date_added desc";
} else
if($orderby == 'product_price_asc') {
   $orderby_query = "order by product_price asc";
} else
if($orderby == 'product_price_desc'){
   $orderby_query = "order by product_price desc";
} else
if($orderby == ''){
   $orderby_query = "";
} else {
unset($orderby); }
?>


3. Buat file .PHP dengan nama create_clothing_table.php di dalam folder phpScripts
Buka Notepad++, pilih File, klik Open, cari file create_clothing_table.php di dalam folder phpScripts.
Isikan sama seperti script warna biru di bawah lalu jangan lupa di-save :
<?php
// connect to your MySQL database here
require "connect_to_mysql.php";
// Create an sql command structure for creating a table
$sqlCommand = "CREATE TABLE clothing (
           id int(11) NOT NULL auto_increment,
        product_name varchar(35) NOT NULL,
        product_price decimal(16) NOT NULL,
        product_brand varchar(16) NOT NULL,
        category varchar(24) NOT NULL,
        subcategory varchar(24) NOT NULL,
        type varchar(24) NOT NULL,
           bahan text(24) NOT NULL,
        color text(24) NOT NULL,
        size varchar(16) NOT NULL,       
        product_details text NOT NULL,
        designCategory varchar(16) NOT NULL,
        date_added date NOT NULL,
                PRIMARY KEY (id),
                UNIQUE KEY product_name (product_name)
                )ENGINE = InnoDB";
if (mysql_query($sqlCommand)){
    echo "Your clothing table has been created successfully!";
} else {
    echo "CRITICAL ERROR: clothing table has not been created.";
}
?>


4. Buat file .PHP dengan nama template_page.php di D:\TUTOR WEB\RIANKLIK\
Buka Notepad++, pilih File, klik Open, cari file template_page.php di D:\TUTOR WEB\RIANKLIK\.
Isikan sama seperti script warna biru di bawah lalu jangan lupa di-save :

<?php
///// Adam's Pagination Logic /////////////////////////////////////////////////////
$nr = mysql_num_rows($sql); // Get total of Num rows from the database query
// Get pn from URL vars if it is present
if (isset($_GET['pn'])) {
    // filter everything but numbers for security(new)
    $pn = preg_replace('#[^0-9]#i', '', $_GET['pn']);
    // filter everything but numbers for security(deprecated)   
    //$pn = ereg_replace("[^0-9]", "", $_GET['pn']);
    // If the pn URL variable is not present force it to be value of page number 1
    } else {
    $pn = 1;
}
//This is where we set how many database items to show on each page
$itemsPerPage = 12;
// Get the value of the last page in the pagination result set
$lastPage = ceil($nr / $itemsPerPage);
// Be sure URL variable $pn(page number)
// is no lower than page 1 and no higher than $lastpage
if ($pn < 1) { // If it is less than 1
    $pn = 1; // force if to be 1
    } else if ($pn > $lastPage) { // if it is greater than $lastpage
    $pn = $lastPage; // force it to be $lastpage's value
}
// This creates the numbers to click in between the next and back buttons
// This section is explained well in the video that accompanies this script
$centerPages = "";
$sub1 = $pn - 1;
$sub2 = $pn - 2;
$add1 = $pn + 1;
$add2 = $pn + 2;

if ($pn == 1) {
    $centerPages .= '&nbsp; <span class="pagNumActive">'. $pn .'</span> &nbsp;';
    $centerPages .= '&nbsp;
    <a href="' . $_SERVER['PHP_SELF']. '?pn='. $add1 .'">'. $add1 .'</a>
    &nbsp;';
} else if ($pn == $lastPage) {
    $centerPages .= '&nbsp;
    <a href="' . $_SERVER['PHP_SELF'] . '?pn=' . $sub1 . '">' . $sub1 . '</a>
    &nbsp;';
    $centerPages .= '&nbsp; <span class="pagNumActive">' . $pn . '</span> &nbsp;';
} else if ($pn > 2 && $pn < ($lastPage - 1)) {
    $centerPages .= '&nbsp;
    <a href="' . $_SERVER['PHP_SELF'] . '?pn=' . $sub2 . '">' . $sub2 . '</a>
    &nbsp;';
    $centerPages .= '&nbsp;
    <a href="' . $_SERVER['PHP_SELF'] . '?pn=' . $sub1 . '">' . $sub1 . '</a>
    &nbsp;';
    $centerPages .= '&nbsp; <span class="pagNumActive">' . $pn . '</span> &nbsp;';
    $centerPages .= '&nbsp;
    <a href="' . $_SERVER['PHP_SELF']  . '?pn=' . $add1 . '">' . $add1 . '</a>
    &nbsp;';
    $centerPages .= '&nbsp;
    <a href="' . $_SERVER['PHP_SELF']  . '?pn=' . $add2 . '">' . $add2 . '</a>
    &nbsp;';
} else if ($pn > 1 && $pn < $lastPage) {
    $centerPages .= '&nbsp;
    <a href="' . $_SERVER['PHP_SELF'] . '?pn=' . $sub1 . '">' . $sub1 . '</a>
    &nbsp;';
    $centerPages .= '&nbsp; <span class="pagNumActive">' . $pn . '</span> &nbsp;';
    $centerPages .= '&nbsp;
    <a href="' . $_SERVER['PHP_SELF'] . '?pn=' . $add1 . '">' . $add1 . '</a>
    &nbsp;';
}
// This line sets the "LIMIT" range...
// the 2 values we place to choose a range of rows from database in our query
$limit = 'LIMIT ' .($pn - 1) * $itemsPerPage .',' .$itemsPerPage;

?>

5. Buat file .PHP dengan nama template_page2.php di D:\TUTOR WEB\RIANKLIK\
Buka Notepad++, pilih File, klik Open, cari file template_page2.php di D:\TUTOR WEB\RIANKLIK\.
Isikan sama seperti script warna biru di bawah lalu jangan lupa di-save :
<?php
/////////////////////// Adam's Pagination Display Setup /////////////////////////////////
$paginationDisplay = ""; // Initialize the pagination output variable
// This code runs only if the last page variable is not equal to 1,
// if it is only 1 page we require no paginated links to display
if ($lastPage != "1"){
    // This shows the user what page they are on, and the total number of pages
    $paginationDisplay .= 'Page <strong>' . $pn . '</strong>
    of ' . $lastPage. '&nbsp;  &nbsp;  &nbsp; ';
    // If we are not on page 1 we can place the Back button
    if ($pn != 1) {
        $previous = $pn - 1;
        $paginationDisplay .= '&nbsp; <a href="'. $_SERVER['PHP_SELF'] .'?pn='. $previous .'
        style="text-decoration:none"">
        Back
        </a>
        ';
    }
    // Lay in the clickable numbers display here between the Back and Next links
    $paginationDisplay .= '<span class="paginationNumbers">' . $centerPages . '</span>';
    // If we are not on the very last page we can place the Next button
    if ($pn != $lastPage) {
        $nextPage = $pn + 1;
        $paginationDisplay .= '&nbsp; <a href="'. $_SERVER['PHP_SELF'] .'?pn='. $nextPage .'">
        Next
        </a>
        ';
    }
}
/////////////////////////// END Adam's Pagination Display Setup ///////////////////////////////
?>


6. Buat file .PHP dengan nama create_clothingStock_table.php di dalam folder phpScripts
Buka Notepad++, pilih File, klik Open, cari file create_clothing_table.php di dalam folder phpScripts.
Isikan sama seperti script warna biru di bawah lalu jangan lupa di-save :
<?php
// connect to your MySQL database here
require "connect_to_mysql.php";
// Create an sql command structure for creating a table
$sqlCommand = "CREATE TABLE clothingStock (
        stock_id int(11) NOT NULL auto_increment,
        product_name varchar(35) NOT NULL,
        store_name varchar(35) NOT NULL,
        color text(24) NOT NULL,
        size varchar(16) NOT NULL,
        stock_amount varchar(16) NOT NULL,
        date_added date NOT NULL,

        PRIMARY KEY (stock_id)
)ENGINE = InnoDB";

if (mysql_query($sqlCommand)){
    echo "Your clothingStock table has been created successfully!";
} else {
    echo "CRITICAL ERROR: clothingStock table has not been created.";
}
?>


7. Buat file .PHP dengan nama clothing_starRating.php di D:\TUTOR WEB\RIANKLIK\
Buka Notepad++, pilih File, klik Open, cari file clothing_starRating.php di D:\TUTOR WEB\RIANKLIK\.
Isikan sama seperti script warna biru di bawah lalu jangan lupa di-save :
<?php
    $sqltotalSale = mysql_query("SELECT*FROM clothingTotalSales
    WHERE product_name='$product_nameS' AND color='$colorS' AND size='$sizeS'");
    while($row=mysql_fetch_array($sqltotalSale)){
        //------ tambahan untuk hilangkan error saat tabel kosong ------ //
        if (!empty($sqltotalSale)){               
            $quantity=$row["quantity"];
        }
        // ------------------------------------------------------------- //
        if ($quantity >=0 && $quantity <=10){
            $sqlStar = mysql_query("SELECT * FROM starRating where rating='0-10'");
            while($row=mysql_fetch_array($sqlStar)){
                if (!empty($sqlStar)){       
                    $s_id=$row["s_id"];
                }
            }   
        }else
        if ($quantity >=11 && $quantity <=20){
            $sqlStar = mysql_query("SELECT * FROM starRating where rating='11-20'");
            while($row=mysql_fetch_array($sqlStar)){
                if (!empty($sqlStar)){       
                    $s_id=$row["s_id"];
                }
            }   
        }else
        if ($quantity >=21 && $quantity <=30){
            $sqlStar = mysql_query("SELECT * FROM starRating where rating='21-30'");
            while($row=mysql_fetch_array($sqlStar)){
                if (!empty($sqlStar)){       
                    $s_id=$row["s_id"];
                }
            }   
        }else
        if ($quantity >=31 && $quantity <=40){
            $sqlStar = mysql_query("SELECT * FROM starRating where rating='31-40'");
            while($row=mysql_fetch_array($sqlStar)){
                if (!empty($sqlStar)){       
                    $s_id=$row["s_id"];
                }
            }   
        }else
        if ($quantity >=41 && $quantity <=50){
            $sqlStar = mysql_query("SELECT * FROM starRating where rating='41-50'");
            while($row=mysql_fetch_array($sqlStar)){
                if (!empty($sqlStar)){       
                    $s_id=$row["s_id"];
                }
            }   
        }else
        if ($quantity >=51 && $quantity <=60){
            $sqlStar = mysql_query("SELECT * FROM starRating where rating='51-60'");
            while($row=mysql_fetch_array($sqlStar)){
                if (!empty($sqlStar)){       
                    $s_id=$row["s_id"];
                }
            }   
        }else
        if ($quantity >=61 && $quantity <=70){
            $sqlStar = mysql_query("SELECT * FROM starRating where rating='61-70'");
            while($row=mysql_fetch_array($sqlStar)){
                if (!empty($sqlStar)){       
                    $s_id=$row["s_id"];
                }
            }   
        }else
        if ($quantity >=71 && $quantity <=80){
            $sqlStar = mysql_query("SELECT * FROM starRating where rating='71-80'");
            while($row=mysql_fetch_array($sqlStar)){
                if (!empty($sqlStar)){       
                    $s_id=$row["s_id"];
                }
            }   
        }else
        if ($quantity >=81 && $quantity <=90){
            $sqlStar = mysql_query("SELECT * FROM starRating where rating='81-90'");
            while($row=mysql_fetch_array($sqlStar)){
                if (!empty($sqlStar)){       
                    $s_id=$row["s_id"];
                }
            }   
        }else
        if ($quantity >=91 && $quantity <=100){
            $sqlStar = mysql_query("SELECT * FROM starRating where rating='91-100'");
            while($row=mysql_fetch_array($sqlStar)){
                if (!empty($sqlStar)){       
                    $s_id=$row["s_id"];
                }
            }   
        }else
        if ($quantity >=101){
            $sqlStar = mysql_query("SELECT * FROM starRating where rating='>101'");
            while($row=mysql_fetch_array($sqlStar)){
                if (!empty($sqlStar)){       
                    $s_id=$row["s_id"];
                }
            }   
        }else{
        }// closing if ...       
    } // closing while ...
?>


8. Buat file .PHP dengan nama clothing_dynamic_list.php di D:\TUTOR WEB\RIANKLIK\
Buka Notepad++, pilih File, klik Open, cari file clothing_dynamic_list.php di D:\TUTOR WEB\RIANKLIK\.
Isikan sama seperti script warna biru di bawah lalu jangan lupa di-save :

<?php   
if (!empty($sqlStar)){
    // memeriksa apa ada product_name di dalam tabel clothingTotalSales
    $sqlCheck1=mysql_query("SELECT sale_id FROM clothingTotalSales
    WHERE product_name='$product_name' LIMIT 1");
    $productMatch=mysql_num_rows($sqlCheck1); // Count the output amount
    if (!empty($sqlCheck1)){   
        if($productMatch > 0){
            $dynamicList.='<div id="thumb1" >
                <a  class="swipebox" href="clothing_images1/'.$id.'.jpg"
                title="'.$product_name.'">
                <img  class="overme" data-alt-src="clothing_images2/'.$id.'.jpg"
                src="clothing_images1/'.$id.'.jpg" width="216" height="216"
                alt="img4" style="border-color:#D6D6F3; border-style:solid;
                border-width:1px" />
                </a>
               
                <div style="padding-top:5px; padding-bottom:5px">
                    <img src="star_images/'.$s_id.'.svg" width="100" height="20"/>
                </div>
               
                <font color="#000000" style="font-size:15px; font-weight:bold">
                <a class="besar" href="#" >'.$product_name.'</a></font>
               
                <a href="clothing_comment.php?id='.$id.'" title="Comment">
                <img  src="svg_images/comment2.svg" width="13" height="13"/></a>   
                    <br/>
                <font color="#000000" style="font-size:13px; font-style:italic">
                '.$product_brand.'
                '.$category.'
                '.$type.'
                '.$size.'
                '.$color.'
                '.$subcategory.'
                </font>
                    <br/>
                <font color="#000000" style="font-size:15px; font-weight:bold">
                Rp.&nbsp'. number_format($product_price,0,',','.').'
                &nbsp;&nbsp;
                </font>
                <a href="clothing_prod.php?id='.$id.'" title="Product Detail">
                <button><img  src="svg_images/cart3black.svg" width="13" height="13"/>
                </button></a>
            </div>';
        }else {
            $dynamicList.='<div id="thumb1">
                <a  class="swipebox" href="clothing_images1/'.$id.'.jpg" 
                title="'.$product_name.'" alt="1">
                <img  class="overme" data-alt-src="clothing_images2/'.$id.'.jpg"
                src="clothing_images1/'.$id.'.jpg" width="216" height="216"
                alt="img4" style="border-color:#D6D6F3; border-style:solid;
                border-width:1px" /></a>
               
                <font color="#000000" style="font-size:15px; font-weight:bold">
                <a class="besar" href="#" >'.$product_name.'</a></font>
               
                <a href="clothing_comment.php?id='.$id.'" title="Comment"><img 
                src="svg_images/comment2.svg" width="13" height="13"/></a>   
                    <br/>
                <font color="#000000" style="font-size:13px; font-style:italic">
                '.$product_brand.'
                '.$category.'
                '.$type.'
                '.$size.'
                '.$color.'
                '.$subcategory.'
                </font>
                    <br/>
                <font color="#000000" style="font-size:15px; font-weight:bold">
                Rp.&nbsp'. number_format($product_price,0,',','.').'
                    &nbsp;&nbsp;
                </font>
                <a href="clothing_prod.php?id='.$id.'" title="Product Detail">
                <button><img  src="svg_images/cart3black.svg" width="13" height="13"/>
                </button></a>
            </div>';   
        }
    }
}else {
            $dynamicList.='<div id="thumb1">
                   
            <a  class="swipebox" href="clothing_images1/'.$id.'.jpg" 
            title="<h2>'.$product_name.'</h2>" alt="1">
            <img  class="overme" data-alt-src="clothing_images2/'.$id.'.jpg"
            src="clothing_images1/'.$id.'.jpg" width="216" height="216" alt="img4"
            style="border-color:#D6D6F3;
            border-style:solid; border-width:1px" /></a>
           
            <font color="#000000" style="font-size:15px; font-weight:bold">
            <a class="besar" href="#" >'.$product_name.'</a></font>
                                                           
            <a href="clothing_comment.php?id='.$id.'" title="Comment"><img 
            src="svg_images/comment2.svg" width="13" height="13"/></a>   
                <br/>
            <font color="#000000" style="font-size:13px; font-style:italic">
            '.$product_brand.'
            '.$category.'
            '.$type.'
            '.$size.'
            '.$color.'
            '.$subcategory.'
            </font>
                <br/>
            <font color="#000000" style="font-size:15px; font-weight:bold">
            Rp.&nbsp'. number_format($product_price,0,',','.').'
            &nbsp;&nbsp;
            </font>
            <a href="clothing_prod.php?id='.$id.'" title="Product Detail">
            <button><img  src="svg_images/cart3black.svg" width="13"
            height="13"/></button></a>
        </div>';   
} // closing if ...
?>


9. Buat file .PHP dengan nama create_subClothing_table.php di dalam folder phpScripts
Buka Notepad++, pilih File, klik Open, cari file create_subClothing_table.php di dalam folder phpScripts.
Isikan sama seperti script warna biru di bawah lalu jangan lupa di-save :

<?php
// connect to your MySQL database here
require "connect_to_mysql.php";
// Create an sql command structure for creating a table
$sqlCommand = "CREATE TABLE subClothing (
        id int(11) NOT NULL auto_increment,
        subClothing varchar(50) NOT NULL,
        date_added date NOT NULL,
        PRIMARY KEY (id)
  )ENGINE = InnoDB";

if (mysql_query($sqlCommand)){
    echo "Your subClothing table has been created successfully!";
} else {
    echo "CRITICAL ERROR: subClothing table has not been created.";
}
?>

10. Buat file .PHP dengan nama template_clothingHeader.php di D:\TUTOR WEB\RIANKLIK\
Buka Notepad++, pilih File, klik Open, cari file template_clothingHeader.php di D:\TUTOR WEB\RIANKLIK\.
Isikan sama seperti script warna biru di bawah lalu jangan lupa di-save :

<?php
// ------------------ Logo ----------------------- //
    include_once("template_logo.php");
// --------------------------------------------------- //
?>

<div id="top_menu">
    <?php
    // dibuat session disini agar jika di-link ke halaman lain maka
    // c_id adalah c_id session dan tidak bisa dirubah dengan c_id yang lain
    // yang mana c_id session tersebut hanya terjadi jika ada $_SESSION['manager']
        if( !empty($_SESSION['manager']) ){
            $manager_name=($_SESSION['manager']);
           
            $custsql=mysql_query("SELECT*FROM customer WHERE customer_name='$manager_name' ")
            or die(mysql_error());
                       
            while($row = mysql_fetch_array($custsql)){
            $c_id=$row['c_id'];
            $_SESSION['c_id']=$c_id;
            }
        }
    ?>
    <?php include_once("clothing_topMenu2.php"); ?>       
</div><!--- closing top_menu --->
<!-- Jika ada SESSION['manager'] maka keranjang    terlihat --->           
<?php
if(isset($_SESSION['manager']) ){
?>
   <?php include_once("top_menu2_clothing.php"); ?>
<?php
}
?>
<div id="menu">
    <?php include_once("template_navmenu_header.php"); ?>
</div> <!----closing menu------>



11. Buat file .PHP dengan nama clothing_topMenu2.php di D:\TUTOR WEB\RIANKLIK\
Buka Notepad++, pilih File, klik Open, cari file clothing_topMenu2.php di D:\TUTOR WEB\RIANKLIK\.

Isikan sama seperti script warna biru di bawah lalu jangan lupa di-save :
<!-- Jika ada SESSION['manager'] maka pilihan Register tidak terlihat --->
    <?php
        if( !isset($_SESSION['manager']) ){
    ?>
        <a href="customer_register.php">
        <font style="font-size:13px; font-family:'Trebuchet MS',
        Arial, Helvetica, sans-serif">Register</font>
        </a>
    <?php
        echo ' &nbsp;|';
    }
    ?>        
<!----------------------------------------------------------------------->
<!---- Jika ada SESSION['manager'] maka pilihan Login tidak terlihat --->
    <?php
    if( !isset($_SESSION['manager']) ){
    ?>
        <a href="customer_login.php">
        <font style="font-size:13px; font-family:'Trebuchet MS',
        Arial, Helvetica, sans-serif">Login</font>
        </a>
    <?php
        echo ' &nbsp;|';
    }
    ?>        
<!----------------------------------------------------------------------->
<!-- Jika ada SESSION['manager'] maka pilihan Logout terlihat --->
    <?php
        if( !empty($_SESSION['manager']) ){
    ?>
        <a href="logout.php">
        <font style="font-size:13px; font-family:'Trebuchet MS',
        Arial, Helvetica, sans-serif">Logout</font>
        </a>
    <?php
        echo ' &nbsp;|';
    }
    ?>        
<!----------------------------------------------------------------------->
<!-- Jika ada SESSION['manager'] maka pilihan Edit terlihat --->
    <?php
        if( !empty($_SESSION['manager']) ){
    ?>
        <a href='customer_edit.php'>
        <font style="font-size:13px; font-family:'Trebuchet MS',
        Arial, Helvetica, sans-serif">Edit</font>
        </a>                      
    <?php
        echo ' &nbsp;|';
    }
    ?>
<!----------------------------------------------------------------------->
<!-- Jika ada SESSION['manager'] maka pilihan Pesanan terlihat --->
    <?php
        if( !empty($_SESSION['manager']) ){
    ?>
        <a href='customer_clothingOrder_list.php?cid=<?php echo $c_id; ?>'>
        <font style="font-size:13px; font-family:'Trebuchet MS',
        Arial, Helvetica, sans-serif">Pesanan</font>
        </a>
    <?php
        echo ' &nbsp;|';
    }
    ?>                    
<!----------------------------------------------------------------------->
<!-- Jika ada SESSION['manager'] maka pilihan Konfirmasi Pembayaran terlihat -->
    <?php
        if( !empty($_SESSION['manager']) ){
    ?>
        <a href='clothing_konfirmasiP.php'>
        <font style="font-size:13px; font-family:'Trebuchet MS',
        Arial, Helvetica, sans-serif">Konfirmasi</font>
        </a>
    <?php
        echo ' &nbsp;|';
    }
    ?>                    
<!----------------------------------------------------------------------->       
    <a href="caraBelanja.php">
    <font style="font-size:13px; font-family:'Trebuchet MS',
    Arial, Helvetica, sans-serif">Cara Belanja</font>
    </a>
    &nbsp;|
    <a href="about.php">
    <font style="font-size:13px; font-family:'Trebuchet MS',
    Arial, Helvetica, sans-serif">About Us</font>
    </a>
    &nbsp;|
    <a href="contact.php">
    <font style="font-size:13px; font-family:'Trebuchet MS',
    Arial, Helvetica, sans-serif">Contact Us</font>
    </a>
    <?php
        if( !empty($_SESSION['manager']) ){
        echo ' &nbsp;|';
    ?>
    <a href='clothing_prodComment.php'>
    <font style="font-size:13px; font-family:'Trebuchet MS',
    Arial, Helvetica, sans-serif">Comment </font>
    </a>                     
    <?php
    }
    ?>
         
12. Buat file .PHP dengan nama clothing_searchWrap.php di D:\TUTOR WEB\RIANKLIK\
Buka Notepad++, pilih File, klik Open, cari file clothing_searchWrap.php di D:\TUTOR WEB\RIANKLIK\.
Isikan sama seperti script warna biru di bawah lalu jangan lupa di-save :

<div id="search_wrap">
    <?php include_once("clothing_searchContainer.php"); ?>
</div> <!----closing search_wrap------>



13. Buat file .PHP dengan nama clothing_searchContainer.php di D:\TUTOR WEB\RIANKLIK\
Buka Notepad++, pilih File, klik Open, cari file clothing_searchContainer.php di D:\TUTOR WEB\RIANKLIK\.
Isikan sama seperti script warna biru di bawah lalu jangan lupa di-save :

<div id="searchContainer">
    <div id="search_left">
        <form id="search" name="search" method="post"
        action="clothingSearchResult.php" style="font-size:15px;
        font-family:'Trebuchet MS', Arial, Helvetica, sans-serif">
       
        <input name="searchquery" type="text" placeholder="Search here ..." 
        style="width: 190px; font-size:15px; font-family:'Trebuchet MS',
        Arial, Helvetica, sans-serif"/>
           
        <input type="submit" name="submit" id="submitSearch" value="Go"
        style="font-size:15px; font-family:'Trebuchet MS',
        Arial, Helvetica, sans-serif"/>
       
        </form>
    </div> <!--- END search_left --->
   
    <div id="search_right">
        <font style="font-size:20px; font-family:'Trebuchet MS',
        Arial, Helvetica, sans-serif">
        <?php
        if( isset($_SESSION['manager']) ){
        ?>
        Login as
        <a class="besar" href="#">
        <?php
        echo $manager_name;
        ?>
        </a>
        <?php
        } else {
        ?>
        Silahkan <a href="customer_register.php">Register</a> atau 
        <a href="customer_login.php">Login</a>, gratis!
        <?php
        }
        ?>
         </font>
    </div> <!--- END search_right --->
</div><!--- END searchContainer --->


14. Buat file .PHP dengan nama insert_subClothing_data.php di dalam folder phpScripts
Buka Notepad++, pilih File, klik Open, cari file insert_subClothing_data.php di dalam folder phpScripts.
Isikan sama seperti script warna biru di bawah lalu jangan lupa di-save :

<?php
// connect to your MySQL database here
require "connect_to_mysql.php";
// Create an sql command structure for creating a table
$sqlCommand ="INSERT INTO subClothing
(id, subClothing, date_added)
VALUES
( '1' ,  'Baju Muslim' ,  now()),
( '2' ,  'Shirt'  ,  now()),
( '3' ,   'T-shirt'  ,  now()),
( '4' ,  'Polo'  ,  now()),
( '5' ,  'Baju Batik'   ,  now()),
( '6' , 'V-neck'  ,  now()),
( '7' , 'O-neck'  ,  now()),
( '8' , 'Jacket' ,  now()),
( '9' , 'Hoodies' ,  now()),
( '10', 'Sweater' ,  now()),
( '11' , 'Cardigan' ,  now()),
( '12' , 'Jas' ,  now()),
( '13' , 'Vests' ,  now()),
( '14' , 'Jeans' ,  now()),
( '15' , 'Pants' ,  now()),
( '16' , 'Shorts' ,  now()),
( '17' , 'Celana Muslim' ,  now()),
( '18' , 'None' ,  now())
";
if (mysql_query($sqlCommand)){
    echo "Your subClothing data has been inserted successfully!";
} else {
    echo "CRITICAL ERROR: subClothing data has not been inserted.";
}
?>


15. Buat folder dengan nama swipebox di dalam folder js
16. Buka website swipebox

klik download, extract dan buka foldernya,
swipebox_3




Copy semua isi folder src, paste-kan di dalam folder swipebox
swipebox_1



17. Buka Notepad++, pilih File, klik Open, cari file template_links_head.php di D:\TUTOR WEB\RIANKLIK\
Tambahkan
sama seperti script warna biru di bawah lalu jangan lupa di-save :
 
<script type="text/javascript" src="js/swipebox/jquery.swipebox.js"></script>

 
<link href="js/swipebox/css/swipebox.css" rel="stylesheet" type="text/css" />


18. Buka Notepad++, pilih File, klik Open, cari file template_links_head2.php di dalam folder admin
Tambahkan sama seperti script warna biru di bawah lalu jangan lupa di-save :

<script type="text/javascript" src="../js/swipebox/jquery.swipebox.js"></script>

<link href="../js/swipebox/css/swipebox.css" rel="stylesheet" type="text/css" />

19. Buat file .PHP dengan nama template_leftContentMens.php di D:\TUTOR WEB\RIANKLIK\
Buka Notepad++, pilih File, klik Open, cari file template_leftContentMens.php di D:\TUTOR WEB\RIANKLIK\. Isikan sama seperti script warna biru di bawah lalu jangan lupa di-save :


<!----------------------TYPER ------------------------------------->      
<div id="typer" style="margin-left:10px; margin-top:20px; font-size:20px;
font-family:'Palatino Linotype', 'Book Antiqua', Palatino, serif; text-align:center">
</div>
<!--------------------------------------------------------------->         
    <br />
<!----------------- ACCORDION --------------------------------------->   
<div id="accordion" class="accord">
    <div class="accord-1" >Clothing</div>
        <div class="accord-textA" style="font-size:13px">
           <!---------------------- 1 ------------------------------>
        <img src="../svg_images/small69black.svg" width="12" height="12"/>
        <a href="#">
        <?php
        if (isset($subClothing[0])){
            echo $subClothing[0];
        }
        ?>  
        <?php
        // untuk menampilkan jumlah item 
        $query = "SELECT subcategory, COUNT(product_name) FROM clothing
                  WHERE subcategory='$subClothing[0]' AND category='Mens'";
        $result = mysql_query($query) or die(mysql_error());
        //Print out result
        while($row = mysql_fetch_array($result)){
              echo "&nbsp;(". $row['COUNT(product_name)'] .")";
        }
        ?>
        <br/>
        </a>  
        <!---------------------- 2 ------------------------------> 
        <img src="../svg_images/small69black.svg" width="12" height="12"/>
        <a href="#">
        <?php
        if (isset($subClothing[1])){
            echo $subClothing[1];
        }
        ?>  
        <?php
        // untuk menampilkan jumlah item 
        $query = "SELECT subcategory, COUNT(product_name) FROM clothing
                  WHERE subcategory='$subClothing[1]' AND category='Mens'";
        $result = mysql_query($query) or die(mysql_error());
        //Print out result
        while($row = mysql_fetch_array($result)){
              echo "&nbsp;(". $row['COUNT(product_name)'] .")";
        }
        ?>
        <br/>
        </a>  
        <!---------------------- 3 ------------------------------>  
        <img src="../svg_images/small69black.svg" width="12" height="12"/>
        <a href="mensTshirt">
        <?php
        if (isset($subClothing[2])){
            echo $subClothing[2];
        }
        ?>  
        <?php
        // untuk menampilkan jumlah item 
        $query = "SELECT subcategory, COUNT(product_name) FROM clothing
                  WHERE subcategory='$subClothing[2]' AND category='Mens'";
        $result = mysql_query($query) or die(mysql_error());
        //Print out result
        while($row = mysql_fetch_array($result)){
              echo "&nbsp;(". $row['COUNT(product_name)'] .")";
        }
        ?>
        <br/>
        </a>  
       
        <!---------------------- 4 ------------------------------>  
        <img src="../svg_images/small69black.svg" width="12" height="12"/>
        <a href="#">
        <?php
        if (isset($subClothing[3])){
            echo $subClothing[3];
        }
        ?>  
        <?php
        // untuk menampilkan jumlah item 
        $query = "SELECT subcategory, COUNT(product_name) FROM clothing
                  WHERE subcategory='$subClothing[3]' AND category='Mens'";
        $result = mysql_query($query) or die(mysql_error());
        //Print out result
        while($row = mysql_fetch_array($result)){
              echo "&nbsp;(". $row['COUNT(product_name)'] .")";
        }
        ?>
        <br/>
        </a> 
        <!---------------------- 5 ------------------------------>  
        <img src="../svg_images/small69black.svg" width="12" height="12"/>
        <a href="#">
        <?php
        if (isset($subClothing[4])){
            echo $subClothing[4];
        }
        ?>  
        <?php
        // untuk menampilkan jumlah item 
        $query = "SELECT subcategory, COUNT(product_name) FROM clothing
                  WHERE subcategory='$subClothing[4]' AND category='Mens'";
        $result = mysql_query($query) or die(mysql_error());
        //Print out result
        while($row = mysql_fetch_array($result)){
              echo "&nbsp;(". $row['COUNT(product_name)'] .")";
        }
        ?>
        <br/>
        </a>          
        <!---------------------- 6 ------------------------------> 
        <img src="../svg_images/small69black.svg" width="12" height="12"/>
        <a href="#">
        <?php
        if (isset($subClothing[5])){
            echo $subClothing[5];
        }
        ?>  
        <?php
        // untuk menampilkan jumlah item 
        $query = "SELECT subcategory, COUNT(product_name) FROM clothing
                  WHERE subcategory='$subClothing[5]' AND category='Mens'";
        $result = mysql_query($query) or die(mysql_error());
        //Print out result
        while($row = mysql_fetch_array($result)){
              echo "&nbsp;(". $row['COUNT(product_name)'] .")";
        }
        ?>
        <br/>
        </a>  
        <!---------------------- 7 ------------------------------>
        <img src="../svg_images/small69black.svg" width="12" height="12"/>
        <a href="#">
        <?php
        if (isset($subClothing[6])){
            echo $subClothing[6];
        }
        ?>  
        <?php
        // untuk menampilkan jumlah item 
        $query = "SELECT subcategory, COUNT(product_name) FROM clothing
                  WHERE subcategory='$subClothing[6]' AND category='Mens'";
        $result = mysql_query($query) or die(mysql_error());
        //Print out result
        while($row = mysql_fetch_array($result)){
              echo "&nbsp;(". $row['COUNT(product_name)'] .")";
        }
        ?>
        <br/>
        </a>  
        <!---------------------- 8 ------------------------------>  
        <img src="../svg_images/small69black.svg" width="12" height="12"/>
        <a href="#">
        <?php
        if (isset($subClothing[7])){
            echo $subClothing[7];
        }
        ?>  
        <?php
        // untuk menampilkan jumlah item 
        $query = "SELECT subcategory, COUNT(product_name) FROM clothing
                  WHERE subcategory='$subClothing[7]' AND category='Mens'";
        $result = mysql_query($query) or die(mysql_error());
        //Print out result
        while($row = mysql_fetch_array($result)){
              echo "&nbsp;(". $row['COUNT(product_name)'] .")";
        }
        ?>
        <br/>
        </a>  
        <!---------------------- 9 ------------------------------>  
        <img src="../svg_images/small69black.svg" width="12" height="12"/>
        <a href="#">
        <?php
        if (isset($subClothing[8])){
            echo $subClothing[8];
        }
        ?>  
        <?php
        // untuk menampilkan jumlah item 
        $query = "SELECT subcategory, COUNT(product_name) FROM clothing
                  WHERE subcategory='$subClothing[8]' AND category='Mens'";
        $result = mysql_query($query) or die(mysql_error());
        //Print out result
        while($row = mysql_fetch_array($result)){
              echo "&nbsp;(". $row['COUNT(product_name)'] .")";
        }
        ?>
        <br/>
        </a> 
        <!---------------------- 10 ------------------------------>  
        <img src="../svg_images/small69black.svg" width="12" height="12"/>
        <a href="#">
        <?php
        if (isset($subClothing[9])){
            echo $subClothing[9];
        }
        ?>  
        <?php
        // untuk menampilkan jumlah item 
        $query = "SELECT subcategory, COUNT(product_name) FROM clothing
                  WHERE subcategory='$subClothing[9]' AND category='Mens'";
        $result = mysql_query($query) or die(mysql_error());
        //Print out result
        while($row = mysql_fetch_array($result)){
              echo "&nbsp;(". $row['COUNT(product_name)'] .")";
        }
        ?>
        <br/>
        </a>          
        <!---------------------- 11 ------------------------------>
        <img src="../svg_images/small69black.svg" width="12" height="12"/>
        <a href="#">
        <?php
        if (isset($subClothing[10])){
            echo $subClothing[10];
        }
        ?>  
        <?php
        // untuk menampilkan jumlah item 
        $query = "SELECT subcategory, COUNT(product_name) FROM clothing
                  WHERE subcategory='$subClothing[10]' AND category='Mens'";
        $result = mysql_query($query) or die(mysql_error());
        //Print out result
        while($row = mysql_fetch_array($result)){
              echo "&nbsp;(". $row['COUNT(product_name)'] .")";
        }
        ?>
        <br/>
        </a>  
        <!---------------------- 12 ------------------------------>
        <img src="../svg_images/small69black.svg" width="12" height="12"/>
        <a href="#">
        <?php
        if (isset($subClothing[11])){
            echo $subClothing[11];
        }
        ?>  
        <?php
        // untuk menampilkan jumlah item 
        $query = "SELECT subcategory, COUNT(product_name) FROM clothing
                  WHERE subcategory='$subClothing[11]' AND category='Mens'";
        $result = mysql_query($query) or die(mysql_error());
        //Print out result
        while($row = mysql_fetch_array($result)){
              echo "&nbsp;(". $row['COUNT(product_name)'] .")";
        }
        ?>
        <br/>
        </a>  
        <!---------------------- 13 ------------------------------>  
        <img src="../svg_images/small69black.svg" width="12" height="12"/>
        <a href="#">
        <?php
        if (isset($subClothing[12])){
            echo $subClothing[12];
        }
        ?>  
        <?php
        // untuk menampilkan jumlah item 
        $query = "SELECT subcategory, COUNT(product_name) FROM clothing
                  WHERE subcategory='$subClothing[12]' AND category='Mens'";
        $result = mysql_query($query) or die(mysql_error());
        //Print out result
        while($row = mysql_fetch_array($result)){
              echo "&nbsp;(". $row['COUNT(product_name)'] .")";
        }
        ?>
        <br/>
        </a>  
        <!---------------------- 14 ------------------------------>  
        <img src="../svg_images/small69black.svg" width="12" height="12"/>
        <a href="#">
        <?php
        if (isset($subClothing[13])){
            echo $subClothing[13];
        }
        ?>  
        <?php
        // untuk menampilkan jumlah item 
        $query = "SELECT subcategory, COUNT(product_name) FROM clothing
                  WHERE subcategory='$subClothing[13]' AND category='Mens'";
        $result = mysql_query($query) or die(mysql_error());
        //Print out result
        while($row = mysql_fetch_array($result)){
              echo "&nbsp;(". $row['COUNT(product_name)'] .")";
        }
        ?>
        <br/>
        </a> 
        <!---------------------- 15 ------------------------------>  
        <img src="../svg_images/small69black.svg" width="12" height="12"/>
        <a href="#">
        <?php
        if (isset($subClothing[14])){
            echo $subClothing[14];
        }
        ?>  
        <?php
        // untuk menampilkan jumlah item 
        $query = "SELECT subcategory, COUNT(product_name) FROM clothing
                  WHERE subcategory='$subClothing[14]' AND category='Mens'";
        $result = mysql_query($query) or die(mysql_error());
        //Print out result
        while($row = mysql_fetch_array($result)){
              echo "&nbsp;(". $row['COUNT(product_name)'] .")";
        }
        ?>
        <br/>
        </a>          
        <!---------------------- 16 ------------------------------>
        <img src="../svg_images/small69black.svg" width="12" height="12"/>
        <a href="#">
        <?php
        if (isset($subClothing[15])){
            echo $subClothing[15];
        }
        ?>  
        <?php
        // untuk menampilkan jumlah item 
        $query = "SELECT subcategory, COUNT(product_name) FROM clothing
                  WHERE subcategory='$subClothing[15]' AND category='Mens'";
        $result = mysql_query($query) or die(mysql_error());
        //Print out result
        while($row = mysql_fetch_array($result)){
              echo "&nbsp;(". $row['COUNT(product_name)'] .")";
        }
        ?>
        <br/>
        </a>  
        <!---------------------- 17 ------------------------------>  
        <img src="../svg_images/small69black.svg" width="12" height="12"/>
        <a href="#">
        <?php
        if (isset($subClothing[16])){
            echo $subClothing[16];
        }
        ?>  
        <?php
        // untuk menampilkan jumlah item 
        $query = "SELECT subcategory, COUNT(product_name) FROM clothing
                  WHERE subcategory='$subClothing[16]' AND category='Mens'";
        $result = mysql_query($query) or die(mysql_error());
        //Print out result
        while($row = mysql_fetch_array($result)){
              echo "&nbsp;(". $row['COUNT(product_name)'] .")";
        }
        ?>
        <br/>
        </a>  
    </div> <!---------- closing accord-textA ------------->
</div> <!-- END of accord -->
<!--------------------------------------------------------------->                    


20. Buka website selectable jquery ui



Pilih Download


Pada bagian Widgets, pilih Accordion



Klik Download, extract file, buka foldernya,


copy file JScript dengan nama jquery-ui, paste-kan di dalam folder js


21. Buka website jquery typer
js_typer 1 dan js_typer_2



Pilih versi terbaru lalu klik Download now



extract, lalu buka foldernya, copy file JScript dengan nama jquery.typer dan paste-kan di dalam folder js

22. Buka Notepad++, pilih File, klik Open, cari file template_links_head.php di D:\TUTOR WEB\RIANKLIK\
Tambahkan sama seperti script warna biru di bawah lalu jangan lupa di-save :

<script type="text/javascript" src="js/jquery.typer.js"></script>

<script type="text/javascript" src="js/jquery-ui.js"></script>


23. Buka Notepad++ ,pilih File, klik Open, cari file template_js_body.php di D:\TUTOR WEB\RIANKLIK\
Isikan sama seperti script warna biru di bawah lalu jangan lupa di-save :

<!-- JS for FREE swipebox -->
<script type="text/javascript">
;( function( $ ) {

    $( '.swipebox' ).swipebox();
} )( jQuery );
</script>

<!-- JS for typing effect  -->
<script type='text/javascript'>
var win = $(window),
    foo = $('#typer');
    foo.typer(['RIANKLIK:', 'SELAMAT DATANG' ]);
</script>

<!-- JS for collapsible accordion -->
<!--- agar tinggi div = auto height tambahkan heightStyle: "content" -->
<script type="text/javascript">
$(function() {
$( "#accordion" ).accordion({
collapsible: true,
heightStyle: "content"
});
});
</script>
<!-- END of JS for collapsible accordion -->


24. Buat file .PHP dengan nama template_rightContentMensClothing.php di D:\TUTOR WEB\RIANKLIK\
Buka Notepad++, pilih File, klik Open, cari file template_rightContentMensClothing.php di D:\TUTOR WEB\RIANKLIK\. Isikan sama seperti script warna biru di bawah lalu jangan lupa di-save :

 <div id="pagNum1" align="left" style="font-family:'Trebuchet MS',
Arial, Helvetica, sans-serif; font-size:15px">
<!-------------------------ORDER BY ------------------------------->
    <form method='get' style="display: inline;" name='orderby_form'>
    <select name='orderby' onChange="orderby_form.submit();"
    style="font-size:14px; width: 150px; font-family:'Trebuchet MS',
    Arial, Helvetica, sans-serif">
   
    <option style="font-size:14px; font-family:'Trebuchet MS',
    Arial, Helvetica, sans-serif" value='date_added_desc'
        <?php
            if(isset($_GET['orderby'])){
            $selected[$orderby]=isset($selected[$orderby]);
            print $selected[$orderby];
            } 
        ?>>Date Added
    </option>
    <option style="font-size:14px; font-family:'Trebuchet MS',
    Arial, Helvetica, sans-serif" value='product_name_asc'
        <?php
            if(isset($_GET['orderby'])){
            $selected[$orderby]=isset($selected[$orderby]);
            print $selected[$orderby];
            } 
        ?>>Product Name
    </option>
    <option style="font-size:14px; font-family:'Trebuchet MS',
    Arial, Helvetica, sans-serif" value='product_price_asc'
        <?php
            if(isset($_GET['orderby'])){
            $selected[$orderby]=isset($selected[$orderby]);
            print $selected[$orderby];
            } 
        ?>>Price (Low - High)
    </option>
    <option style="font-size:14px; font-family:'Trebuchet MS',
    Arial, Helvetica, sans-serif" value='product_price_desc'
        <?php
            if(isset($_GET['orderby'])){
            $selected[$orderby]=isset($selected[$orderby]);
            print $selected[$orderby];
            } 
        ?>>Price (High - Low)
    </option>
    <option style="font-size:14px; font-family:'Trebuchet MS',
    Arial, Helvetica, sans-serif" value='' 
        <?php
            if(isset($_GET['orderby'])){
            $selected[$orderby]=isset($selected[$orderby]);
            print $selected[$orderby];
            } 
    ?>>Order by
    </option>
   
    </select>
    </form>
<!-------------------END of ORDER BY ------------------------------->
&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp;&nbsp;
&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp;&nbsp;
&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp;&nbsp;
    <?php
        echo $paginationDisplay;
    ?>
</div> <!--- END pagNum --->
     <br/>
    <br/>
    <br />
<?php echo $dynamicList; ?>


25. Buka Notepad++ ,pilih File, klik Open, cari file style.css di dalam folder styleCSS
Isikan sama seperti script warna biru di bawah lalu jangan lupa di-save

/*--------------- Pagination----------------- */
#pagNum {
    height: 25px;
    width: 670px;
    left: 240px;
    padding: 10px;
    position: absolute;
    top: 370px;
    border-bottom-width: 1px;
    border-bottom-style: solid;
    border-bottom-color: #999;
    margin-left: 15px;
}
#pagNum1 {
    height: 25px;
    width: 670px;
    left: 240px;
    padding: 10px;
    position: absolute;
    top: 15px;
    border-bottom-width: 1px;
    border-bottom-style: solid;
    border-bottom-color: #999;
    margin-left: 15px;
}
#pagNum1 {
        height: 25px;
        width: 670px;
        left: 240px;
        padding: 10px;
        position: absolute;
        top: 15px;
        border-bottom-width: 1px;
        border-bottom-style: solid;
        border-bottom-color: #999;
        margin-left: 15px;
    }
#pagNum2 {
    height: 25px;
    width: 670px;
    padding: 10px;
    position: absolute;
    top: 0px;
    border-bottom-width: 1px;
    border-bottom-style: solid;
    border-bottom-color: #999;
    margin-left: 15px;
    left: 0px;
}
#pagNum3 {
height: 25px;
width: 670px;
left: 0px;
padding: 10px;
position: relative;
top: 15px;
border-bottom-width: 1px;
border-bottom-style: solid;
border-bottom-color: #999;
margin-left: auto;
margin-right: auto;
}
#pagNum4 {
    height: 25px;
    width: 670px;
    left: 125px;
    padding: 10px;
    position: absolute;
    top: 20px;
    border-bottom-width: 1px;
    border-bottom-style: solid;
    border-bottom-color: #999;
    margin-left: 15px;
}
#pagNumTopOL {
    height: 25px;
    width: 775px;
    padding: 10px;
    border-bottom-width: 1px;
    border-bottom-style: solid;
    border-bottom-color: #999;
    margin-left: auto;
    margin-right: auto;
    float: left;
}
#pagNumMember {
    height: 25px;
    width: 670px;
    left: 130px;
    padding: 10px;
    position: absolute;
    top: 15px;
    border-bottom-width: 1px;
    border-bottom-style: solid;
    border-bottom-color: #999;
    margin-left: 15px;
}

.pagNumActive{
    -moz-border-radius: 3px 3px 3px 3px;  /* for Firefox */
    -webkit-border-radius: 3px 3px 3px 3px; /* for Webkit-Browsers */
    border-radius: 3px 3px 3px 3px; /* regular */
    opacity: 0.8; /* Transparent Background 50% */
    color: #000;
    border: #060 1px solid;
    background-color: #EEEEEE;
    padding-left: 3px;
    padding-right: 3px;
}
.paginationNumbers a:link{
    -moz-border-radius: 3px 3px 3px 3px;  /* for Firefox */
    -webkit-border-radius: 3px 3px 3px 3px; /* for Webkit-Browsers */
    border-radius: 3px 3px 3px 3px; /* regular */
    opacity: 0.8; /* Transparent Background 50% */
    color: #000;
    text-decoration: none;
    border:#999 1px solid; background-color: #f0f0f0;
    padding-left: 3px; padding-right: 3px;
}
.paginationNumbers a:visited{
    -moz-border-radius: 3px 3px 3px 3px;  /* for Firefox */
    -webkit-border-radius: 3px 3px 3px 3px; /* for Webkit-Browsers */
    border-radius: 3px 3px 3px 3px; /* regular */
    opacity: 0.8; /* Transparent Background 50% */
    color: #000;
    text-decoration: none;
    border:#999 1px solid; background-color: #f0f0f0;
    padding-left: 3px; padding-right: 3px;
}
.paginationNumbers a:hover{
    -moz-border-radius: 3px 3px 3px 3px;  /* for Firefox */
    -webkit-border-radius: 3px 3px 3px 3px; /* for Webkit-Browsers */
    border-radius: 3px 3px 3px 3px; /* regular */
    opacity: 0.8; /* Transparent Background 50% */
    color: #000;
    text-decoration: none;
    border: #060 1px solid;
    background-color: #E1E1F7;
    padding-left: 3px;
    padding-right: 3px;
}
.paginationNumbers a:active{
    -moz-border-radius: 3px 3px 3px 3px;  /* for Firefox */
    -webkit-border-radius: 3px 3px 3px 3px; /* for Webkit-Browsers */
    border-radius: 3px 3px 3px 3px; /* regular */
    opacity: 0.8; /* Transparent Background 50% */
    color: #000;
    text-decoration: none;
    border:#060 1px solid; background-color: #f0f0f0;
    padding-left: 3px; padding-right: 3px;
}

/*--------------- accordion----------------- */
.accord {
    padding: 10px;
    width: 215px;
    top: 0px;
    margin: 0px;
    left: 0px;
    overflow: hidden;
    position: relative;
}

.accord-1 {
    height: 18px;
    width: 153px;
    top: 0px;
    float: left;
    margin: 0px;
    border: 1px solid #CCC;
    vertical-align: middle;
    padding-top: 0px;
    padding-right: 6px;
    padding-bottom: 8px;
    padding-left: 6px;
    font-family: "Palatino Linotype", "Book Antiqua", Palatino, serif;
    font-size: 12px;
    background-color: #999;
}

.accord-textA {
    padding: 10px;
    width: 140px;
    top: 0px;
    float: left;
    overflow: hidden;
    position: relative;
    font-family: "Palatino Linotype", "Book Antiqua", Palatino, serif;
    font-size: 13px;
    margin: 0px;
}

.accord-1:hover {
    background-color: #CCC;   
}
.accord-2:hover {
    background-color: #CCC;   
}
.accord-3:hover {
    background-color: #CCC;   
}

/*--------------- search----------------- */
#search_wrap {
    padding: 0px;
    height: 45px;
    width: 960px;
    margin-right: auto;
    margin-left: auto;
    position: relative;
    background-color: #ecf0f1;
}
#searchContainer {
    -moz-border-radius: 0px 0px 8px 8px;  /* for Firefox */
    -webkit-border-radius: 0px 0px 8px 8px; /* for Webkit-Browsers */
    border-radius: 0px 0px 8px 8px;
    width: 940px;
    margin-right: auto;
    margin-left: auto;
    position: relative;
    overflow: hidden;
    padding-top: 10px;
    padding-bottom: 10px;
}

#search_left {
    float: left;
    width: 470px;
    overflow: hidden;
    position: relative;
}
#search_right {
    float: left;
    width: 470px;
    overflow: hidden;
    position: relative;
    text-align: right;
}


26. Upload semua file dan folder baru ke web server
27. Buka dengan browser 192.168.88.111/phpScripts/


Klik secara berurutan, pertama klik create_clothing_table.php, lalu create_subClothing_table.php, insert_subClothing_data.php, dan create_clothingStock_table.php

26. Buka dengan browser 192.168.88.111




Pada pilihan Pria, klik Pakaian



Sampai disini, gambar diatas adalah tampilan halaman mensClothing.php dalam keadaan kosong, belum ada gambar gambar produk

Comments

Popular posts from this blog

Sepuluh Langkah Membuat Warnet