Posts Tagged jquery

[jQuery] 1.3.2 和 1.4 的比較

jQuery 近來都差不多成為最多人用的javascript framework 了。

近來jQuery 推出新的release 1.4. 聽聞 performance 改善了很多。

No. of Function Calls (因為減少了很多不必要 method 的call,可能就是大大改善performance 的原因)

dom 的insertion 看來需要的時間真是快了很多 (ie 系列快了很多)

Read the rest of this entry »

  • Share/Bookmark

, , ,

2 Comments

8 種 Outlook like AJAX Calendar Components 的介紹和看法

chowky 覺得類似 outlook , ical 的 AJAX 的calendar好似很散,所以決定整理一下。

1. Day Pilot

這是一個為ASP.NET 而寫的一個component。成熟程度好高。還備有schedule 的 version 。

有Lite (免費,但功能會少一點)和P和Pro (當然要收錢的) version 。

daypilot1daypilot2
Source: http://www.daypilot.org

2. dhtmlxScheduler

這都是一個很成熟的component. 非常smooth。有齊daily , weekly, monthly,commercial application 其實是必定要完整的。否則一定沒有人買。

不過如果你個想寫的都要是GNU (opensource) 才可以免費使用這個calendar ,否則就要收錢了。(Dual Licensing 亦不能用的呢)

dhtml1

Demo: http://dhtmlx.com/docs/products/dhtmlxScheduler/livedemo.shtml
Source: http://dhtmlx.com/docs/products/dhtmlxScheduler/

Read the rest of this entry »

  • Share/Bookmark

, , , , , , ,

2 Comments

[jQuery] 利用 jqeury 和 css 建立一個navigation menu

Chowky 一向欣賞這位作者所做的simple and elegent 效果和教學。

只是簡單的4個steps 就可以做到以下的效果。

Step 1: HTML 都是利用ul 和li

1
2
3
4
5
6
7
8
<ul id="topnav">
    <li><a href="#">Home</a></li>
    <li><a href="#">Services</a></li>
    <li><a href="#">Portfolio</a></li>
    <li><a href="#">Blog</a></li>
    <li><a href="#">About</a></li>
    <li><a href="#">Contact</a></li>
</ul>

Step 2. CSS
要留意的是,現在是還未add span 的,span 會在之後用jquery 加上去。

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
ul#topnav {
	margin: 0;
	padding: 0;
	list-style: none;
	float: left;
	font-size: 1.1em;
}
ul#topnav li{
	margin: 0;
	padding: 0;
	overflow: hidden;  /*--Important - Masking out the hover state by default--*/
	float: left;
	height:40px;
}
ul#topnav a, ul#topnav span { /*--The <a> and <span> share the same properties since the <span>  will be a duplicate of the <a> tag--*/
	padding: 10px 20px;
	float: left;
	text-decoration: none;
	color: #fff;
	background: url(a_bg.gif) repeat-x;
	text-transform: uppercase;
	clear: both;
	width: 100%;
	height: 20px;
	line-height: 20px; /*--Vertical alignment of text--*/
}
ul#topnav a{ /*--This is basically the hover state of navigation--*/
	color: #555;
	background-position: left bottom;
}
ul#topnav span{ /*--Default state of navigation--*/
	background-position: left top;
}

Step 3. 利用jquery製造的animation effect

a). embed jquery 的library

b). 利用jqeury 去製造animation,shift image -40px pixel向上。

$(document).ready(function() {
 
	$("#topnav li").prepend("<span></span>"); //Throws an empty span tag right before the a tag
 
	$("#topnav li").each(function() { //For each list item...
		var linkText = $(this).find("a").html(); //Find the text inside of the <a> tag
		$(this).find("span").show().html(linkText); //Add the text in the <span> tag
	}); 
 
	$("#topnav li").hover(function() {	//On hover...
		$(this).find("span").stop().animate({
			marginTop: "-40" //Find the <span> tag and move it up 40 pixels
		}, 250);
	} , function() { //On hover out...
		$(this).find("span").stop().animate({
			marginTop: "0"  //Move the <span> back to its original state (0px)
		}, 250);
	});
 
});

Source: http://www.sohtanaka.com/web-design/animate-navigation-with-css-jquery/
Demo: http://www.sohtanaka.com/web-design/examples/fancy-navigation/

  • Share/Bookmark

, , ,

4 Comments

[AIR] jQuery Browser

又一個新的air application。

jQuery 都採用air來implement這個api browser。

可見,外國的對air的接受性真係比想像中好。
pic1
Read the rest of this entry »

  • Share/Bookmark

, ,

No Comments

[jQuery] Image Flip 為圖片加上倒影和動畫效果

這幾天,真是太忙,是經濟轉好的signal?

希望快點轉好。(chowky 持有很多股票….哈)~

回歸主題。

可以選擇horizontal 和vertical flip,而且reflection 效果都可以turn off.

加入website 之中,立即可以提昇水準。(哈 chowky 一向不相信即時見效的東西)

imageflip

License:  License Free

Demo: http://webmuch.com/demos/image_flip_demo/flip.html

Source: http://webmuch.com/image-flip-using-jquery/

  • Share/Bookmark

, ,

No Comments

[jQuery] 利用jquery 指定print area

Chowky 認為這個教學非常有用,因為可以指定要print 的area,不用整個screen print 出來,可以save 不少paper。

而且是利用jquery create iframe on the fly,所以應該不會因為iframe 而影響web page。

以後就可以指定print 指定的content

Source: http://www.bennadel.com/index.cfm?dax=blog:1591.view

Supported Browser: FireFox, IE 7, Safari, Chrome

  • Share/Bookmark

, ,

No Comments

[jQuery] 折角/捲曲效果,peeling effect

chowky 認為這個效果可塑性非常大,用途很廣泛,而且是利用jquery造出來的~

效果不錯。

sample1

Read the rest of this entry »

  • Share/Bookmark

, , , , ,

No Comments

[jQuery] Create an Image Rotator with Description (CSS/jQuery)

Update: 原文中新增了fade out / fade in effect.

這個image rotator,有description ,而且可以hide,effect 簡潔。

不錯,可惜load image 的時候沒有 loader image ,令人不知道是loading new image.

imagerotator1

Read the rest of this entry »

  • Share/Bookmark

, , ,

No Comments

[jQuery] MP3 Player 播放器

Javascript 都可以做到mp3 player ,jQuery 強大的程度,可以做到progressive reading,即是可以有buffer,不用下載完畢後才播放。值得研究。

當然,architecture 方面: javascript  communicate with flash component to get the MP3,所以可以做到purely javascript 控制。chowky 不知道所提供的swf 要怎寫的,不過值得稱讚。

還可以加入playlist,player style 又可以轉變。

jplayer1jplayer21

Read the rest of this entry »

  • Share/Bookmark

, ,

No Comments

[jQuery] Full Calendar with drag and drop function

Chowky 覺得這個component 很簡單,沒有花巧的effect,已經不錯的,effect 可以自己再找不同的再plug 上去。

總括來講,一個不錯的calendar component in jquery.

fullcalendar

Source: http://arshaw.com/fullcalendar/

License: MIT

  • Share/Bookmark

, ,

1 Comment