jQuery Mobile手机网站案例

一、总结

一句话总结:jQuery Mobile是纯手机框架,和amazeui和bootstrap都可以做手机网站。

1、另一款文本编辑器?

jd编辑器

二、jQuery Mobile手机网站案例

1、index.php

 <?php
include 'common/config.php'; $sql='select * from message'; $rst=mysql_query($sql); ?>
<!doctype html>
<html>
<head>
<meta charset="UTF-8">
<title>index</title>
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<link rel="stylesheet" href="jm/mobile.css">
<script src="jm/jquery.js"></script>
<script src="jm/mobile.js"></script>
<link rel="stylesheet" href="css/idangerous.swiper.css">
<link rel="stylesheet" href="css/style.css">
<link rel="stylesheet" href="css/swiper-demos.css">
<script src="js/idangerous.swiper-1.9.1.min.js"></script>
<script src="js/idangerous.swiper.scrollbar-1.2.js"></script>
<script src="js/swiper-demos.js"></script>
<style>
*{
min-width:0px!important;
min-height:0px!important;
} .home-device,.swiper-main,.swiper-container,.swiper1,.swiper-wrapper,.swiper-slide{
width:100%;
overflow:hidden;
} *{
font-family: 微软雅黑;
}
</style>
</head>
<body>
<div data-role="page" id="pageone">
<div data-role="header">
<h1>手机动漫</h1>
<div data-role="navbar">
<ul>
<li><a href="#a" data-theme='b' data-icon="home" data-rel='dialog'>查看动漫</a></li>
<li><a href="add.php" data-theme='b' data-icon='grid' data-rel='dialog'>发布动漫</a></li>
</ul>
</div>
</div> <div data-role="content">
<div class="home-device"><a class="arrow-left" href="#"></a> <a class="arrow-right" href="#"></a>
<div class="swiper-main">
<div class="swiper-container swiper1">
<div class="swiper-wrapper">
<div class="swiper-slide"> <img src="data:images/slider1-1.jpg" width='100%'> </div>
<div class="swiper-slide"> <img src="data:images/slider1-2.jpg" width='100%'> </div>
</div>
</div>
</div>
<div class="pagination pagination1"></div>
</div>
<p>国产动画《新大头儿子和小头爸爸》已于2013年11月28日晚20:00在中央电视台少儿频道《银河剧场》栏目首播。这部动画由诸多微小而有趣的故事组成,是一部很适合中国孩子观看的动画片。大头儿子、是个活泼可爱的大头的小孩,小头爸爸、是个给予大头儿子的是想象力的满足和对他一颗童心的一位好爸爸,围裙妈妈是一个有洁癖,但却很关心大头儿子和小头爸爸的一位家庭主妇,这三个人组成了一个三口之家,他们是中国现代家庭教育典型的缩影。这是一个普通而又平凡的家庭,但它所具有的特质是任何一个家庭都不具备的,因为它是由强烈的现实性与浓郁的幻想性所构成的。</p>
</div> <div data-role="footer">
<h1>www.lampym.com</h1>
</div>
</div> <div data-role='page' id='a'>
<div data-role='header' data-theme='b'>
<h1>查看动漫</h1>
</div>
<div data-role='content' data-theme='a'>
<ul data-role="listview" data-inset="true" data-theme='e'>
<?php
while($row=mysql_fetch_assoc($rst)){
echo "<li><a href=''>{$row['title']}</a></li>";
}
?> </ul>
</div>
<div data-role='footer' data-theme='b'>
<h1>www.lampym.com</h1>
</div>
</div>
<div data-role='page' id='b'>
<div data-role='header' data-theme='b'>
<h1>发布动漫</h1>
</div>
<div data-role='content' data-theme='a'> </div>
<div data-role='footer' data-theme='b'>
<h1>www.lampym.com</h1>
</div>
</div> </body>
<script>
function size(){
h=$('.swiper-slide img').eq(0).height();
$('.swiper-slide').height(h);
$('.swiper-slide').parentsUntil('.home-device').height(h);
} $(window).load(function(){
size();
}); $(window).resize(function(){
size();
}); $(window).on("orientationchange",function(){
size();
}); </script>
</html>

2、add.php

 <!doctype html>
<html>
<head>
<meta charset="UTF-8">
<title>index</title>
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<link rel="stylesheet" href="jm/mobile.css">
<script src="jm/jquery.js"></script>
<script src="jm/mobile.js"></script>
<style>
*{
font-family: 微软雅黑;
} #content{
height:100px!important;
}
</style>
</head>
<body>
<div data-role="page" id="pageone">
<div data-role='header'>
<h1>发布动漫</h1>
</div>
<div data-role="content">
<form action="insert.php" method='post' data-transition="slide" data-ajax='false'>
<label for="username">发布者:</label>
<input type="text" name='username' id='username'> <label for="title">动漫标题:</label>
<input type="text" name='title' id='title'> <label for="content">动漫内容:</label>
<textarea name="content" id="content" rows='10'></textarea> <input type="submit" data-role='button' value='提交' data-inline='true' data-theme='b'>
<input type="reset" data-role='button' value='取消' data-inline='true' data-theme='e'>
</form>
</div> <div data-role="footer">
<h1>www.lampym.com</h1>
</div>
</div>
</body>
</html>

3、insert.php

 <?php
include 'common/config.php'; $username=$_POST['username'];
$time=time();
$title=$_POST['title'];
$content=$_POST['content']; $sql="insert into message(username,title,content,time) values('{$username}','{$title}','{$content}','{$time}')";
if(mysql_query($sql)){
header('location:/lampweb');
}
?>
 
 
 
 

jQuery Mobile手机网站案例的更多相关文章

  1. jquery.mobile手机网页简要

    先上最终效果: 最近做了一个用手机浏览器访问的web应用,采用较流行的HTML5,为了提高开发效率节省时间决定采用现有开源框架,免去了自己做设计与兼容性. 一些比较优秀的框架:10大优秀的移动Web应 ...

  2. 手机新闻网站,手持移动新闻,手机报client,jQuery Mobile手机新闻网站,手机新闻网站demo,新闻阅读器开发

    我们坐在地铁.经常拿出新浪手机查看新闻.腾讯新闻,或者看新闻,等刷微信功能.你有没有想过如何实现这些目标. 移动互联网.更活泼. 由于HTML5未来,jQuery Moblie未来. 今天我用jqm的 ...

  3. 手机新闻网站,掌上移动新闻,手机报client,jQuery Mobile手机新闻网站,手机新闻网站demo,新闻阅读器开发

    我们坐在地铁,经常来查看新浪手机新闻,腾讯新闻.或者刷微信看新闻更多功能.你有没有想过如何实现这些目标.移动互联网,更活泼. 因为HTML5到,jQuery Moblie到.今天我用jqm为了给你一个 ...

  4. jQuery Mobile学习日记

    本次主讲人是王思伦啦啦啦~ 框架特性 jQuery Mobile 以“Write Less, Do More”作为目标,为所有的主流移动操作系统平台提供了高度统一的 UI 框架:jQuery 的移动框 ...

  5. jQuery Mobile中文手册:开发入门

    jQuery Mobile 以“Write Less, Do More”作为目标,为所有的主流移动操作系统平台提供了高度统一的 UI 框架:jQuery 的移动框架可以让你为所有流行的移动平台设计一个 ...

  6. 18个jQuery Mobile开发贴士和教程

    jQuery Mobile 是 jQuery 在手机上和平板设备上的版本.jQuery Mobile 不仅会给主流移动平台带来jQuery核心库,而且会发布一个完整统一的jQuery移动UI框架.支持 ...

  7. jQuery Mobile案例,最近用Moon.Web和Moon.Orm做了一套系统

      一.简介 先说说,我们的主题.jQuery Mobile,最近用Moon.Web和Moon.Orm做了一套系统 jQuery Mobile是jQuery 在手机上和平板设备上的版本.jQuery ...

  8. 【学习】一本案例驱动的jQuery Mobile入门书

    清华大学出版社推出的<构建跨平台APP:jQuery Mobile移动应用实战> 提供的全是jQuery Mobile的案例: 手机入侵 题库应用 音乐专辑 通讯录 新闻列表 销售排名 九 ...

  9. SharePoint之使用Jquery Mobile定制自己的手机页面

    最近一直很忙,既要创业,又要工作,还有弄弄自己的小项目(已暂停,http://www.codelove1314.com/,如果你不愿意浪费你的业余时间,喜欢弄点小东西,请联系我),所以虽然有很多东西分 ...

随机推荐

  1. Windows(x86,64bit)升级MySQL 5.7.17免安装版的详细教程

    MySQL需要升级到5.5.3以上版本才支持Laravel 5.4默认的utf8mb64字符编码.因此就把MySQL升级了一下,期间还是遇到些小问题,记录一下以供参考. 升级准备 备份之前MySql目 ...

  2. 《从零開始学Swift》学习笔记(Day 59)——代码排版

    原创文章,欢迎转载.转载请注明:关东升的博客 代码排版包括: 空行.空格.断行和缩进等内容.代码排版内容比較多工作量非常多.可是非常重要. 空行 空行将逻辑相关的代码段分隔开.以提高可读性. 下列情况 ...

  3. 1.1 Introduction中 Apache Kafka™ is a distributed streaming platform. What exactly does that mean?(官网剖析)(博主推荐)

    不多说,直接上干货! 一切来源于官网 http://kafka.apache.org/documentation/ Apache Kafka™ is a distributed streaming p ...

  4. python项目实战-小游戏1

    项目规则: 1.玩家和敌人分别从现有的角色中选择3个角色 2.随机生成目前的血量,和攻击量 3.游戏规则:当玩家向敌人发起攻击,敌人当前的血量=之前的血量-玩家的血量,同理 4.3局两胜 5.自定义玩 ...

  5. Flask项目之手机端租房网站的实战开发(二)

    说明:该篇博客是博主一字一码编写的,实属不易,请尊重原创,谢谢大家! 接着上一篇博客继续往下写 :https://blog.csdn.net/qq_41782425/article/details/8 ...

  6. ubuntu, 修改hosts文件

    介绍下ubuntu下修改host实现域名指向本地的方法. Ubuntu系统的Hosts只需修改/etc/hosts文件,在目录中还有一个hosts.conf文件,刚开始还以为只需要修改这个就可以了,结 ...

  7. 关于android的2.2与4.4的文件读取的一点发现

    好久没有写文章了,本来想写的东西,时间一长,就感觉不想写了.没什么用,到用时.又不知道去哪找了或怎么解决. 有一句话说的好啊,好记性不如烂笔头. 我要做到善于总结.及时整理,额............ ...

  8. [Node] Catch error for async await

    When we try to do MongoDB opration, mongoose return Promise, we can use async/await to simply the co ...

  9. [Angular2 Router] Auxiliary Routes bit by bit

    Article Github Auxiliary Routes is is little bit hard to understand. Here is demo, link You can see ...

  10. php语法同java语法的基本区别(实例项目需求,php才能熟)

    php语法同java语法的基本区别(实例项目需求,php才能熟) 一.总结 看下面 二.PHP基本语法以及和Java的区别 .表示字符串相加 ->同Java中的. $作为变量的前缀,除此之外,变 ...