367. 简约的网上花店网站 大学生期末大作业 Web前端网页制作 html5+css+js

目录

一、网页概述

二、网页文件

 三、网页效果

四、代码展示

1.html

2.CSS

3.JS

五、总结

1.简洁实用

2.使用方便

3.整体性好

4.形象突出

5.交互式强

六、更多推荐


欢迎光临仙女的网页世界!这里有Web前端网页制作的各行各业的案例样式齐全新颖,并持续更新!感谢CSDN,提供了这么好的知识学习、技术交流的平台,让我们在这里相遇,小伙伴们,来吧,让我们一起开启Web前端网页制作的奇妙之旅!

说起Web前端,大学开启这扇技术之门以来,一切起始于兴趣爱好和专业钻研。自16年中大研究生毕业步入社会工作以来,才真正开启了这段奇妙的旅行!在一次次需求分析、成品交付和客户服务的过程中,进行了一次又一次的知识应用的实践和验证。学以致用,实践出真知!从最初的Web前端的迷途小书童到如今的技术专家,多年的服务客户和服务大学生的实践经验,早就驾轻就熟!

 奇妙之处在于:当你得到客户的认可、公司的赞赏和同事的敬仰,尤其是业余时间为广大的大学生提供各种各样的帮助和指引,学弟学妹们一致好评,认为学姐是他们的榜样的时候,你会发现,知识的应用除了体现自身价值,还能实现自我满足!这种感觉是相当奇妙的!

我在CSDN的奇妙旅行,除了学习其他知识和持续发布优质的网页实例之外,后续时间允许的情况下,我会发布前端相关知识的学习和应用的教程。目前提供的服务类型包括:Web前端网页制作的专题研究辅导网页定制大学生课程作业辅导、毕设辅导网页模板源码教程资料技术咨询,以及其他有偿或无偿的服务。如有需要,欢迎随时咨询!能满足你们所需,是我的荣幸!

非常感谢大家的关注和点赞,你们的关注和点赞是我持续创作的动力,谢谢!


一、网页概述

本实例应用html5+css+js: 导航菜单、图片轮翻效果、鼠标悬停图片特效、视频、悬浮菜单、留言表单、登录页面等。适用于大学生网页课程作业设计、公司网页制作等。本网页支持如Dreamweaver、HBuilder、Text 、Vscode 等任意html编辑软件进行编辑修改;支持包括IE、Firefox、Chrome、Safari主流浏览器浏览。


二、网页文件

本网页实例共包含4个页面:


 三、网页效果

以下是本篇文章正文内容,下面案例仅供参考(节选示例):


四、代码展示

1.html

<!doctype html>
<!--[if lt IE 7 ]><html class="ie ie6" lang="en"> <![endif]-->
<!--[if IE 7 ]><html class="ie ie7" lang="en"> <![endif]-->
<!--[if IE 8 ]><html class="ie ie8" lang="en"> <![endif]-->
<!--[if (gte IE 9)|!(IE)]><!-->
<!--条件注释语句,当满足if语句时则执行-->


<html lang="en">
<!--<![endif]-->
<head>
<meta charset="utf-8"><!--编码格式-->
<title>XXX花店-首页</title>

<!--引用js文件-->
<script src="js/jquery-1.8.2.min.js"></script>
<script src="js/common.js"></script>
<script src="js/jquery.easing.1.3.js"></script>
<script src="js/ddsmoothmenu.js"></script>
<script src="js/jquery.flexslider.js"></script>
<script src="js/jquery.elastislide.js"></script>
<script src="js/jquery.jcarousel.min.js"></script>
<script src="js/jquery.accordion.js"></script>
<script src="js/light_box.js"></script>
<script type="text/javascript">$(document).ready(function(){$(".inline").colorbox({inline:true, width:"50%"});});</script>
<!--end js-->

<!-- 适配于手机浏览 ================================================== -->
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">

<!-- CSS ================导入外部样式表================================== -->

<!--可以在<head>部分通过<style>标签定义内部样式表;
当样式需要被应用到很多页面的时候,外部样式表将是理想的选择。
使用外部样式表,就可以通过更改一个文件来改变整个站点的外观-->
<link rel="stylesheet" href="css/style.css">
<link rel="stylesheet" href="css/orange.css">
<link rel="stylesheet" href="css/skeleton.css">
<link rel="stylesheet" href="css/layout.css">
<link rel="stylesheet" href="css/ddsmoothmenu.css"/>
<link rel="stylesheet" href="css/elastislide.css"/>
<link rel="stylesheet" href="css/home_flexslider.css"/>

<link rel="stylesheet" href="css/light_box.css"/>
<script src="js/html5.js"></script>

<!--[if IE]><script src="js/html5.js"></script>
<![endif]-->

<!--[if lt IE 9]>
            <script src="js/html5.js"></script>
        <![endif]-->

</head>
<body>
    <div class="mainContainer big container"><!--主要内容区-->
            <!--Header Block-->
            <div class="header-wrapper">
              <header class="container">
                <div class="head-right">
                      <ul class="top-nav">
                            <li class=""><a href="#">我的账户</a></li>
                            <li class="my-wishlist"><a href="#">收藏</a></li>
                            <li class="checkout"><a href="#" >结算</a></li>
                            <li class="log-in"><a href="account_login.html" >登录</a></li>
                      </ul>
                  <section class="header-bottom"><!--搜索和购物车-->
                  <!--section新标签,与div类似,语义化-->
                    <div class="cart-block"><!--购物车-->
                    <ul>
                        <li>(2)</li>
                        <li><a href="#" title="购物车"><img title="购物车" alt="购物车" src="picture/item_icon.png" /></a></li>
                        <li>购物车</li>
                    </ul>
                    <div id="minicart" class="remain_cart" style="display: none;">
                         <p class="empty">您的购物车共有2件商品</p>
                         <ol>
                             <li>
                                <div class="img-block"><img src="picture/small_img1.png" title="" alt="" /></div>
                                <div class="detail-block">
                                    <h4><a href="#" title="玫瑰">玫瑰</a></h4>
                                    <p>
                                        <strong>1</strong> x ¥99.00
                                        <!--strong用于文本加粗,强调作用-->
                                    </p>
                                    <a href="#" title="Details">细节展示</a>
                                </div>
                                <div class="edit-delete-block">
                                    <a href="#" title="Edit"><img src="picture/edit_icon.png" alt="Edit" title="Edit" /></a>
                                    <!--<img>中“alt”当浏览器无法加载图片时显示替代文本的属性-->
                                    <a href="#" title="Remove"><img src="picture/delete_item_btn.png" alt="Remove" title="Remove" /></a>
                                </div>
                            </li>
                            <li>
                                <div class="img-block"><img src="picture/small_img.png" title="" alt="" /></div>
                                <div class="detail-block">
                                    <h4><a href="#" title="玫瑰">玫瑰</a></h4>
                                    <p>
                                        <strong>1</strong> x ¥99.00
                                    </p>
                                    <a href="#" title="Details">细节展示</a>
                                </div>
                                <div class="edit-delete-block">
                                    <a href="#" title="Edit"><img src="picture/edit_icon.png" alt="Edit" title="Edit" /></a>
                                    <a href="#" title="Remove"><img src="picture/delete_item_btn.png" alt="Remove" title="Remove" /></a>
                                </div>
                            </li>
                            <li>
                                <div class="total-block">共计:<span>¥198.00</span></div>
                                <a href="index.html" title="结算" class="orange-btn">结算</a>
                                <!--<div class="clear"></div>-->
                            </li>
                         </ol>
                    </div>
                </div>
                          <!--搜索框-->
                    <div class="search-block">
                      <input type="text" value="搜索" />
                      <!--定义单行的输入字段,用户可在其中输入文本。默认宽度为 20 个字符。
                      并不是所有的主流浏览器都支持新的input类型。-->
                      <input type="submit" value="submit"/>
                      <!--submit定义提交按钮。提交按钮会把表单数据发送到服务器-->
                    </div>
                  </section>
                </div>
                         <!--LOGO-->
                <h1 class="logo">
                  <img title="Logo" alt="Logo" src="picture/logo.png" /></h1>
                  
                <nav id="smoothmenu1" class="ddsmoothmenu mainMenu">
                <!--nav标签定义导航链接的部分,是H5的新标签,优点是语义化-->
                  <ul id="nav">
                  <!--无序列表-->
                    <li class="active"><a href="index.html">首页</a></li>
                    <li ><a href="category.html">全部商品</a></li>                             
                    <li><a href="contact_us.html">留言板</a></li>
                  </ul>
                </nav>
                <!--响应式导航菜单-->
                <div class="mobMenu">
            <h1>
            <span>菜单</span>
            <a class="menuBox highlight" href="javascript:void(0);"></a>
            <!--javascript:void(0)空链接,没有跳转-->
            <span class="clearfix"></span>
            <!--清除浮动对后面元素的影响-->
            </h1>
            
            <div id="menuInnner" style="display:none;">
            <!--设置默认状态是不显示-->
                   <ul class="accordion"><!--accordion:可折叠的-->
                   <!--无序列表-->
                       <li class="active"><a href="index.html" >首页</a></li>
                    <li class="parent"><a href="category.html" >全部商品</a></li>
                    <li class=""><a href="contact_us.html" >留言板</a></li>
                      <span class="clearfix"></span>
                   </ul>
                  
             </div>      
            </div>                  
                          </div>          
            <!--Banner Block-->
            <section class="banner-wrapper">
              <div class="banner-block container">
                <div class="flexslider"><!--调用框架接口-->
                  <ul class="slides">
                    <li><img title="Banner" alt="Banner" src="picture/banner1.png" /></li>
                    <li><img title="Banner" alt="Banner" src="picture/banner2.png" /></li>
                    <li><img title="Banner" alt="Banner" src="picture/banner3.png" /></li>
                    <li><img title="Banner" alt="Banner" src="picture/banner4.png" /></li>
                  </ul>
                </div>
                <ul class="banner-add">
                  <li class="add1"><a href="#" title=""><img title="add1" alt="add1" src="picture/banner_add1.png" /></a></li>
                  <li class="add2"><a href="#" title=""><img title="add2" alt="add2" src="picture/banner_add2.png" /></a></li>
                </ul>
              </div>
            </section>
            <!--Content Block--><!--内容区-->
            <section class="content-wrapper">
              <div class="content-container container">
                <div class="heading-block">
                  <h1>热卖商品</h1>
                  <ul class="pagination">
                    <li class="grid"><a href="#" title="网格"></a></li>
                    <!--网格状翻转按钮-->
                  </ul>
                </div>

...

2.CSS

代码如下(节选示例):


    html, body, div, span, applet, object, iframe,  h1, h2, h3, h4, h5, h6, p, blockquote, pre,  a, abbr, acronym, address, big, cite, code,  del, dfn, em, img, ins, kbd, q, s, samp,  small, strike, strong, sub, sup, tt, var,  b, u, i, center,  dl, dt, dd, ol, ul, li,  fieldset, form, label, legend,  table, caption, tbody, tfoot, thead, tr, th, td,  article, aside, canvas, details, embed,  figure, figcaption, footer, header, hgroup,  menu, nav, output, ruby, section, summary,  time, mark, audio, video {
    margin: 0;
    padding: 0;
    border: 0;
    font: inherit;/*在一个声明中设置所有的字体属性*/
    vertical-align: baseline;/*设置元素的垂直对齐*/
}
html {
    font-size: 62.5%;
}
/* HTML5 display-role reset for older browsers */

    article, aside, details, figcaption, figure,  footer, header, hgroup, menu, nav, section {
    display: block;/*display:block - 显示块元素的链接,让整体变为可点击链接区域(不只是文本),它允许我们指定宽度*/
}
body {
    line-height: 1;
    border-top:5px solid;
}
ol, ul {
    list-style: none;
}
blockquote, q {
    quotes: none;
}
blockquote:before, blockquote:after,  q:before, q:after {
    content: '';
    content: none;
}
table {
    border-collapse: collapse;
    border-spacing: 0;
}
.left, .columns.left {
                 
    float: left;/*columns:栏,纵队*/
}
.right, .columns.right {
    float: right;
}
.hide {
    display: none;
}
.highlight {
    background: #ff0;
}

    .ie9, .ie9 * {
    font-family: Arial, "Definitely Not Helvetica", sans-serif !important;
}
body {
    background: #fff;
    font-family: "Droid Sans", "HelveticaNeue", Helvetica, Arial, "Lucida Grande", sans-serif;
    font-size: 16px;
    font-size:12px;
    line-height: 1.6;
    color: #555;
    position: relative;
    -webkit-font-smoothing: antialiased;
}
/*给字体做初始化*/
      h1, h2, h3, h4, h5, h6 {
    color: #1b1b1b;
    font-weight: bold;
    line-height: 1.6;
}
h1 a, h2 a, h3 a, h4 a, h5 a, h6 a {
    font-weight: inherit;
}
h1 {
    font-size: 46px;
    font-size: 4.6rem;
    margin-bottom: 12px;
}
h2 {
    font-size: 39px;
    font-size: 3.9rem;
    margin-bottom: 9px;
}
h3 {
    font-size: 29px;
    font-size: 2.9rem;
    margin-bottom: 9px;
}
h4 {
    font-size: 25px;
    font-size: 2.5rem;
    margin-bottom: 3px;
}
h5 {
    font-size: 19px;
    font-size: 1.9rem;
    font-weight: normal;
    margin-bottom: 3px;
}
h6 {
    font-size: 15px;
    font-size: 1.5rem;
    font-weight: normal;
}
.subhead {
    color: #777;
    font-weight: normal;
    margin-bottom: 20px;
}

...

3.JS

代码如下(节选示例):

(function ($, document, window) {
    var
    // Default settings object.    
    // See http://jacklmoore.com/colorbox for details.
    defaults = {
        transition: "elastic",
        speed: 300,
        width: false,
        initialWidth: "600",
        innerWidth: false,
        maxWidth: false,
        height: false,
        initialHeight: "450",
        innerHeight: false,
        maxHeight: false,
        scalePhotos: true,
        scrolling: true,
        inline: false,
        html: false,
        iframe: false,
        fastIframe: true,
        photo: false,
        href: false,
        title: false,
        rel: false,
        opacity: 0.9,
        preloading: true,

        current: "image {current} of {total}",
        previous: "previous",
        next: "next",
        close: "close",
        xhrError: "This content failed to load.",
        imgError: "This image failed to load.",

        open: false,
        returnFocus: true,
        reposition: true,
        loop: true,
        slideshow: false,
        slideshowAuto: true,
        slideshowSpeed: 2500,
        slideshowStart: "start slideshow",
        slideshowStop: "stop slideshow",
        onOpen: false,
        onLoad: false,
        onComplete: false,
        onCleanup: false,
        onClosed: false,
        overlayClose: true,        
        escKey: true,
        arrowKey: true,
        top: false,
        bottom: false,
        left: false,
        right: false,
        fixed: false,
        data: undefined
    },
    
    // Abstracting the HTML and event identifiers for easy rebranding
    colorbox = 'colorbox',
    prefix = 'cbox',
    boxElement = prefix + 'Element',
    
    // Events    
    event_open = prefix + '_open',
    event_load = prefix + '_load',
    event_complete = prefix + '_complete',
    event_cleanup = prefix + '_cleanup',
    event_closed = prefix + '_closed',
    event_purge = prefix + '_purge',
    
    // Special Handling for IE
    isIE = !$.support.opacity && !$.support.style, // IE7 & IE8
    isIE6 = isIE && !window.XMLHttpRequest, // IE6
    event_ie6 = prefix + '_IE6',

    // Cached jQuery Object Variables
    $overlay,
    $box,
    $wrap,
    $content,
    $topBorder,
    $leftBorder,
    $rightBorder,
    $bottomBorder,
    $related,
    $window,
    $loaded,
    $loadingBay,
    $loadingOverlay,
    $title,
    $current,
    $slideshow,
    $next,
    $prev,
    $close,
    $groupControls,
    
    // Variables for cached values or use across multiple functions
    settings,
    interfaceHeight,
    interfaceWidth,
    loadedHeight,
    loadedWidth,
    element,
    index,
    photo,
    open,
    active,
    closing,
    loadingTimer,
    publicMethod,
    div = "div",
    init;

    // ****************
    // HELPER FUNCTIONS
    // ****************
    
    // Convience function for creating new jQuery objects
    function $tag(tag, id, css) {
        var element = document.createElement(tag);

        if (id) {
            element.id = prefix + id;
        }

...


五、总结

设计一个样式美观又人性化的网页,除了具备扎实的专业知识,还需具备美学和人机工程学等相关知识,优秀的网页应具备以下几个特点:

1.简洁实用

尽量以最高效率的方式将用户所要想得到的信息传送给他就是最好的,要去掉所有的冗余的东西;

2.使用方便

要满足使用者的要求,网页适合使用,显示出其功能美;

3.整体性好

围绕一个统一的目标设计,强调整体的功能性; 

4.形象突出

尽量符合网页美的标准,能够使网站的形象得到最大限度的提升,追求雅俗共赏。页面用色协调,布局符合形式美的要求:布局有条理,充分利用美的形式,使网页富有可欣赏性,提高档次。

5.交互式强

发挥网络的优势,想方设法使每个使用者都参与到其中来。


六、更多推荐

关注作者|获取更多源码|优质文章】;Web前端网页制作、大学生毕业设计辅导、期末大作业辅导、模板源码、技术咨询,有兴趣的联系我!

您的支持是我创作的动力!看到这里就【点赞收藏博文】,Thanks!

更多优质博客文章、网页模板点击以下链接查阅:仙女网页设计-CSDN博客


评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包

打赏作者

仙女网页制作

你的鼓励将是我创作的最大动力

¥1 ¥2 ¥4 ¥6 ¥10 ¥20
扫码支付:¥1
获取中
扫码支付

您的余额不足,请更换扫码支付或充值

打赏作者

实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值