|
发表于 2017-1-28 22:43:30
|
显示全部楼层
本帖最后由 ipakk 于 2017-1-28 22:46 编辑
9 D7 g/ E6 d! M
7 Z G% {8 H: [& C向右的柱状图- <div id="bar-chart" class="graphic"></div>
复制代码
s( b) F, o5 G& S脚注
- M& Y( d, ?9 t0 i+ V. ?(刚观察CNN某网站的源码和框架偶然发现:Refugees from countries targeted in Trump's order,源码和框架在这里看:- <!DOCTYPE html>
" F2 \) ?% `1 [5 v - <!--[if IE 7]> <html class="lt-ie9 lt-ie8"> <![endif]-->
8 o0 g. Q( d$ M/ K) M4 h9 w - <!--[if IE 8]> <html class="lt-ie9"> <![endif]-->6 L- f/ A; ~$ B9 J. f5 Q
- <!--[if IE 9 ]> <html class="ie9" lang="en-US"> <![endif]-->
9 \0 G8 o, d' ]: f# B8 ^: I - <!--[if (gt IE 9)|!(IE)]><!--> <html lang="en-US"> <!--<![endif]-->
4 y' N+ d4 c, [ e/ a9 j - <head>
2 s- W7 ?9 p7 F6 H) t& @, |4 K
- d# w. w+ M2 k- <meta charset="utf-8">% [1 u9 g* @7 z: T; Y
- <meta name="robots" content="noindex">
; C8 d4 q7 p! L+ f - <meta http-equiv="X-UA-Compatible" content="IE=edge">
% r' I n) q" {3 W+ r - <meta name="viewport" content="width=device-width, initial-scale=1, minimum-scale=1, maximum-scale=1, user-scalable=no">' n* g6 I# A5 c F% c# K
& A- f+ n; g" l% o2 |- <title>CNN : Graphic : Refugees from countries targeted in Trump's order</title>. f* a: M: n* T. U6 n& N9 y
' z& M' q- l8 a: E- <meta name="title" content="Refugees from countries targeted in Trump's order">+ S& j# _/ r( @2 k% B2 H( \( P
- <meta name="description" content="">
* @' L! G& z1 y& ~8 } - <meta name="keywords" content="">
8 ]+ W5 W! A. M- R! q9 g# {: T& w - <meta name="news_keywords" content="">
& L0 q2 | T9 f; v - <meta name="section" content="">
& a) b3 a: a- R) n' p: v - <meta name="source" content="CNN">8 w/ X; p# G7 s$ l- |7 Q; P
- <meta name="subsection" content="">+ z* r1 j7 c5 L4 o' @9 r
- <meta name="application-name" content="CNN">8 u7 [) j" ~2 H' G$ U; ^ v5 p! [
3 z5 W* h X, k$ ~# Y- <!-- Facebook settings -->
4 i, I/ n F1 f4 k- ? - <meta property="og:description" content="">
2 h, O Y. \- z' M7 b - <meta property="og:image" content="">) J9 O7 b9 x1 N( r1 {
- <meta property="og:type" content="">/ E3 X( ?1 D3 g9 [# s4 Y N( S
- <meta property="og:title" content="Refugees from countries targeted in Trump's order">
- X* C( y* F6 @5 b" Q! v8 y - <meta property="og:url" content="">$ ]; w9 _( F% N5 W2 k, c) Y% t
- <meta property="fb:admins" content="690014395">
& \8 z) C( ^( M/ M% X - <meta property="fb:app_id" content="80401312489">6 ]0 D7 b5 g- d @
- 1 k( _- a( M" z7 @* a
- <!-- Twitter card settings -->: K) x l+ R6 |2 G; I- s6 `
- <meta name="twitter:card" content="summary_large_image">
5 S0 E/ z0 ?& H1 \+ l/ T - <meta name="twitter:site" content="@cnn">' i, N# b6 K( S& b
- <meta name="twitter:site:id" content="759251">
. M* ]! e2 J9 v ~6 u2 W - <meta name="twitter:creator" content="@cnn">+ t6 A! G/ c' E
- <meta name="twitter:title" content="Refugees from countries targeted in Trump's order">7 ^. O' b$ O! @8 F* M/ @- p' n! ^
- <meta name="twitter:description" content="">$ O8 T# G- x7 @6 B
- # y( K# j) p+ ?. I& @, G/ g
- <link rel="canonical" href="">
& U+ U6 c/ L2 E8 w3 k. K: Q6 w6 H- \4 e - <link rel="shortcut icon" href="//cnn.com/favicon.ie9.ico">8 w. k1 J, W5 n* f6 J% x/ O
- <link rel="apple-touch-icon" href="//i.cdn.turner.com/cnn/.e/img/3.0/global/misc/apple-touch-icon.png">
+ V$ Z' I. `. ~8 A+ Q5 d0 }1 x" X- l - <link rel="stylesheet" type="text/css" href="css/graphic-header.css?1485524128" />
8 G1 C( Q3 g2 T: x# z x- b - / z9 c& b+ U; J5 y4 J) ]% `3 s8 O7 b
- <base target="_blank">4 r4 b/ g, R' I' F4 g- h: K
9 S4 E6 }. W5 f- </head>
. }' a* g1 z1 B/ w f& b* K# [
: N0 b+ u, A! f9 G6 e# K, p* ]- <body>
& P2 v- P' c- J- Q - <header>! w1 t+ p4 P _7 p- {
- <!-- javascripts -->
# U2 B% u1 u$ K- S3 ` - " `. z- {: j( j% h" J) M4 I6 I
- <script type="text/javascript" src="js/graphic-header.js?1485524128"></script>
P( M4 m$ s4 u+ _' ^ - <script type="text/javascript" src="//z.cdn.turner.com/cnn/.e/js/libs/jquery-1.9.1.min.js"></script>- Q0 \! s% w% S
- </header>7 F. V5 N* G$ V% {- ], t
- ( t* G5 V. P" M4 B4 a- q1 }( i- v
- <section>
: }" ?/ x5 h. k( | a0 L" o! m - % O& `+ w; M, m* V) \9 V: ?
7 Y7 \2 q# g( K- <div id="meta">. r$ w& X6 H: Q4 e" B
- <h1 class="hed">Refugees from countries targeted in Trump's order</h1>" C( \- o0 |1 v* |6 i% Y6 c& H) ?
- <h2 class="dek">In fiscal 2016, US admitted 36,722 refugees from Iraq, Iran, Syria, Yemen, Sudan, Somalia and Libya.</h2>5 t$ c$ F* Q- v: R6 e
- </div>
# S) ~& K) y4 V O# t5 U
1 I1 P0 I. o: c( y S6 b+ ]6 V- <div id="bar-chart" class="graphic"></div>
# }0 q/ n# Q* v& N
d, B' L( N5 [0 \) d$ U- `- <div id="footer">7 M8 _8 ?, i$ N2 ^, I1 u
-
( q2 ]4 l7 P+ w# I' p* O) A - <p class="source">Source: Refugee Processing Center / US State Department’s Bureau of Population, Refugees and Migration</p>! `" q8 |* ^7 n/ P
- </div>
' [; M( X# @" {2 k7 H2 S - }2 y L0 `1 K! R' O6 X
- <script type="text/javascript">0 b5 h1 n3 e6 s4 E9 {4 Z8 R* s* \* k
- var DATA = [{"label": "Syria", "amt": "12587"}, {"label": "Iraq", "amt": "9880.0"}, {"label": "Somalia", "amt": "9020"}, {"label": "Iran", "amt": "3750.0"}, {"label": "Sudan", "amt": "1458"}, {"label": "Yemen", "amt": "26"}, {"label": "Libya", "amt": "1"}];5 [4 W; J: y Y) j9 l
- </script>
4 T: A3 p( i4 Q. C0 Y* ^+ c9 z, ? - 3 t W+ ^8 V( W5 Q& _! ]
- 9 N$ F1 u* p& M
- </section>
* c, C7 f" K# H) ?9 H - " G r: f {# a0 F2 D
- <footer>
+ C2 D r3 [9 K& l- V; v - <!-- javascripts -->
, I. y+ n1 l0 K! V! W6 h - <script src="//z.cdn.turner.com/cnn/.e/interactive/js/lib/vendor/pym/pym.v1.min.js"></script>
4 p2 [& U$ i7 X& {6 u& u. t - <script src="//z.cdn.cnn.com/cnn/.e/interactive/js/lib/vendor/d3/d3-4.3.0-min.js"></script>
) w" b4 W* T; ^! }8 o9 N
6 ?5 f0 B( v, d8 G* G2 ~-
/ t7 r( U B& i - $ [+ @8 |" C& \; e
-
5 H, K9 u& O& L' O5 S - ! a9 i: k! I6 ]5 w& R8 Z% F
- <script type="text/javascript" src="js/graphic-footer.js?1485524128"></script>
5 H+ V# v4 ?7 }, _
& g( J0 ?' {; i- </footer>
! [# G; m& {% H. a% z7 | - </body>
9 P$ f M- v% g* Z9 X8 _7 H# f5 y - </html>
复制代码 : `- A5 P& R& H' }/ @/ K4 d
1 ]8 `; R5 ^$ s% H+ ?5 a9 f
, M7 e8 e( V: k0 e1 I好像还要画图,用什么工具画? 有谁知道吗,可否推荐一个比较好的工具,谢谢! |
|