2012年3月23日
摘要: 来看下其使用方法:关键的图片的html代码是免不了1 <img src="demo_files/sago.jpg" id="cropbox" />值得一提的是,插件运行后,会将此图片隐藏,复制出2个图片,一张作为背景,而另外一张放在裁剪层。而背景层图片是可以指定的,并非一定要同一张图片,具体参见第5个demo。来看其javascript代码1 jQuery(function(){2 var jcrop_api = jQuery('#cropbox').Jcrop();3 });这是最为简单的形式,可满足基础需求,当然Jcrop 阅读全文
posted @ 2012-03-23 22:56 咖啡戏 阅读(309) 评论(0) 推荐(0) 编辑
摘要: 国内很多第三方提供收藏&分享的站点,比如jiathis、addthis等,这些站点提供的插件虽然引用方便,但都有个问题,点击收藏&分享按钮后事先跳转到该第三方的站点,然后才转向真正的分享插件,而且分享列表上面还是这第三方的logo之类的,而效果又是千篇一律,因此明河就想写一个没有任何第三方logo和中转而且效果出众的收藏&分享插件,我将其命名为$.shareList。demo由于有用到了ajax,请在服务器端启动使用教程1、引入jquery和$.shareList,还有css1 <script type="text/javascript" sr 阅读全文
posted @ 2012-03-23 22:51 咖啡戏 阅读(1306) 评论(0) 推荐(0) 编辑
摘要: 请看实际demo:http://www.36ria.com/demo/password_strength/原理说明:其实原理非常的简单,这里赋予密码强度10个等级,请看progressImg1.png,是一张包含十个状态的图片。给密码框绑定keyup事件,获取密码值,然后使用正则进行判断等级(难点在这里),然后切换进度条的样式。使用教程:创建如下html:1 <div class="form_item clearfix">2 <label>密&nbsp;&nbsp;码:</label>3 <div class=&qu 阅读全文
posted @ 2012-03-23 22:30 咖啡戏 阅读(451) 评论(0) 推荐(0) 编辑
摘要: SimpleModal is a lightweightjQueryPlugin which provides a powerful interface for modal dialog development. Think of it as a modal dialog framework. SimpleModal gives you the flexibility to build whatever you can envision, while shielding you from related cross-browser issues inherent with UI develop 阅读全文
posted @ 2012-03-23 22:20 咖啡戏 阅读(236) 评论(0) 推荐(0) 编辑
摘要: demo一、引入jquery库和yitip的js及其css1 <script type="text/javascript" src="js/jquery-1.4.2.min.js"></script>2 <script type="text/javascript" src="js/jquery.yitip.js"></script>3 <link rel="stylesheet" type="text/css" href= 阅读全文
posted @ 2012-03-23 22:06 咖啡戏 阅读(477) 评论(0) 推荐(0) 编辑
摘要: 今天推荐一个分页工具条插件:Smart Paginator,这个插件用途还是很广的,而且可定制性相当不错,目前内置三种颜色,有需要的话,可以自己改css定制颜色。1.如何使用Smart Paginator?1.1引入以下几个文件1 <script src="jquery-1.4.4.min.js" type="text/javascript"></script>2 <script src="smartpaginator.js" type="text/javascript">< 阅读全文
posted @ 2012-03-23 21:55 咖啡戏 阅读(1413) 评论(0) 推荐(0) 编辑
摘要: demo(ps:RIA之家的全部demo,明河已经托管到github,如果要下载博客的全部demo,传送门在此:https://github.com/minghe/36ria-demo。)已经把验证规则的提示内容翻译成中文了,请看validation-engine-2.2\js\languages\jquery.validationEngine-cn.js。关于时间有二处提示没找到地方,目前没做修改。明河的英文太菜,翻译难免词不达意,欢迎纠正,O(∩_∩)O哈!如何处理ajax验证?典型场景:如何使用Validation-Engine验证用户名或email的存在性?这个需求在大部分的注册页面都 阅读全文
posted @ 2012-03-23 21:50 咖啡戏 阅读(1776) 评论(0) 推荐(1) 编辑
摘要: 普通验证的例子:http://www.position-relative.net/creation/formValidator/ajax验证的例子:http://www.position-relative.net/creation/formValidator/demoSubmit.html引入jquery和插件js、css1 <link rel="stylesheet" href="css/validationEngine.jquery.css" type="text/css" media="screen" 阅读全文
posted @ 2012-03-23 21:44 咖啡戏 阅读(312) 评论(0) 推荐(0) 编辑
摘要: Chosen提供了suggest功能,强大的是实现了选项分组和多选关键词处理。如何使用?引入jquery库和脚本1 <script src="https://ajax.googleapis.com/ajax/libs/jquery/1.7.1/jquery.min.js" type="text/javascript"></script>2 <script src="chosen/chosen.jquery.js" type="text/javascript"></scrip 阅读全文
posted @ 2012-03-23 21:36 咖啡戏 阅读(1269) 评论(0) 推荐(0) 编辑