About
-----
Flot is a Javascript plotting library for jQuery. Read more at the
website:
http://code.google.com/p/flot/
Take a look at the examples linked from above, they should give a good
impression of what Flot can do and the source code of the examples is
probably the fastest way to learn how to use Flot.
Installation
------------
Just include the Javascript file after you've included jQuery.
Generally, all browsers that support the HTML5 canvas tag are
supported.
For support for Internet Explorer < 9, you can use Excanvas, a canvas
emulator; this is used in the examples bundled with Flot. You just
include the excanvas script like this:
<!--[if lte IE 8]><script language="javascript" type="text/javascript" src="excanvas.min.js"></script><![endif]-->
If it's not working on your development IE 6.0, check that it has
support for VML which Excanvas is relying on. It appears that some
stripped down versions used for test environments on virtual machines
lack the VML support.
You can also try using Flashcanvas (see
http://code.google.com/p/flashcanvas/), which uses Flash to do the
emulation. Although Flash can be a bit slower to load than VML, if
you've got a lot of points, the Flash version can be much faster
overall. Flot contains some wrapper code for activating Excanvas which
Flashcanvas is compatible with.
You need at least jQuery 1.2.6, but try at least 1.3.2 for interactive
charts because of performance improvements in event handling.
Basic usage
-----------
Create a placeholder div to put the graph in:
<div id="placeholder"></div>
You need to set the width and height of this div, otherwise the plot
library doesn't know how to scale the graph. You can do it inline like
this:
<div id="placeholder" style="width:600px;height:300px"></div>
You can also do it with an external stylesheet. Make sure that the
placeholder isn't within something with a display:none CSS property -
in that case, Flot has trouble measuring label dimensions which
results in garbled looks and might have trouble measuring the
placeholder dimensions which is fatal (it'll throw an exception).
Then when the div is ready in the DOM, which is usually on document
ready, run the plot function:
$.plot($("#placeholder"), data, options);
Here, data is an array of data series and options is an object with
settings if you want to customize the plot. Take a look at the
examples for some ideas of what to put in or look at the reference
in the file "API.txt". Here's a quick example that'll draw a line from
(0, 0) to (1, 1):
$.plot($("#placeholder"), [ [[0, 0], [1, 1]] ], { yaxis: { max: 1 } });
The plot function immediately draws the chart and then returns a plot
object with a couple of methods.
What's with the name?
---------------------
First: it's pronounced with a short o, like "plot". Not like "flawed".
So "Flot" rhymes with "plot".
And if you look up "flot" in a Danish-to-English dictionary, some up
the words that come up are "good-looking", "attractive", "stylish",
"smart", "impressive", "extravagant". One of the main goals with Flot
is pretty looks.
没有合适的资源?快使用搜索试试~ 我知道了~
资源推荐
资源详情
资源评论
收起资源包目录
resin-4.0.60.zip (614个子文件)
configure.ac 38KB
Makefile.am 11KB
stop.bat 149B
start.bat 146B
jni_socket.c 43KB
config.c 39KB
stream.c 38KB
mod_caucho.c 35KB
jni_os.c 13KB
std.c 12KB
boot.c 8KB
jni_jvmti.c 4KB
jni_jvmdi.c 4KB
memory.c 3KB
memory.c 3KB
java.c 1KB
compile 7KB
fine.conf 269B
configure 591KB
protocol.cpp 25KB
isapi_srun.cpp 12KB
jquery-ui-1.8.4.custom.css 33KB
jquery.ui.theme.css 18KB
default.css 17KB
default.css 8KB
colorbox.css 4KB
jquery.ui.datepicker.css 4KB
default.css 3KB
jquery.ui.button.css 2KB
jquery.ui.core.css 1KB
jquery.ui.tabs.css 1KB
jquery.ui.dialog.css 1KB
jquery.ui.resizable.css 1KB
jquery.ui.slider.css 1KB
jquery.ui.autocomplete.css 1KB
jquery.ui.accordion.css 1KB
jquery.ui.base.css 427B
jquery.ui.progressbar.css 359B
jquery.ui.selectable.css 325B
jquery.ui.all.css 293B
resin_os.def 3KB
isapi_srun.def 218B
isapi_srun.dll 153KB
isapi_srun.dll 135KB
mod_caucho.dll 99KB
mod_caucho.dll 99KB
resin_os.dll 80KB
resin_os.dll 68KB
resinssl.dll 67KB
resinssl.dll 56KB
Resin.IIS.Handler.dll 32KB
queue-timing.eps 36KB
setup.exe 95KB
resin.exe 30KB
xslt-perf.gif 11KB
amber-lifecycle.gif 10KB
loading.gif 9KB
jsp_perf.gif 8KB
jsp_log.gif 7KB
assembler-eg1.gif 7KB
appserver.gif 5KB
jndi_tree.gif 5KB
website_srun.gif 5KB
compiler.gif 4KB
apache_srun.gif 4KB
webserver.gif 4KB
iis_srun.gif 4KB
amber-non-xa.gif 4KB
sticky-sessions.gif 3KB
httpd.gif 3KB
loading.gif 3KB
backup.gif 3KB
srunc.gif 3KB
caucho.gif 3KB
same_srun.gif 2KB
hbleed.gif 1KB
hbleed.gif 1KB
resin-powered.gif 1KB
jsp.gif 904B
bean1.gif 902B
bean.gif 900B
style.gif 899B
script.gif 889B
file.gif 864B
folder.gif 861B
logo.gif 571B
resin_powered.gif 571B
CauchoFLY_red32.gif 419B
CauchoFLY_blu32.gif 418B
background.gif 386B
CauchoFLY_red16.gif 305B
CauchoFLY_blu16.gif 303B
ball8.gif 197B
left_background.gif 165B
left_background.gif 165B
pixel.gif 61B
pixel.gif 61B
config.guess 42KB
cse.h 11KB
resin_os.h 6KB
共 614 条
- 1
- 2
- 3
- 4
- 5
- 6
- 7
资源评论
chen__kai
- 粉丝: 0
- 资源: 2
上传资源 快速赚钱
- 我的内容管理 展开
- 我的资源 快来上传第一个资源
- 我的收益 登录查看自己的收益
- 我的积分 登录查看自己的积分
- 我的C币 登录后查看C币余额
- 我的收藏
- 我的下载
- 下载帮助
安全验证
文档复制为VIP权益,开通VIP直接复制
信息提交成功