JS, HTML & CSS

제이쿼리, 그래프, 그래프 종결자

관리자 | 2013.01.21 15:16 | 조회 10904

 

 

<script language="javascript" type="text/javascript" src="./graph/excanvas.js"></script>
<script type="text/javascript" src="./graph/jquery.jqplot.min.js"></script>
<script type="text/javascript" src="./graph/plugins/jqplot.barRenderer.min.js"></script>
<script type="text/javascript" src="./graph/plugins/jqplot.pieRenderer.min.js"></script>
<script type="text/javascript" src="./graph/plugins/jqplot.categoryAxisRenderer.min.js"></script>
<script type="text/javascript" src="./graph/plugins/jqplot.pointLabels.min.js"></script>
<link rel="stylesheet" type="text/css" href="./graph/jquery.jqplot.min.css" />

<script class="code" type="text/javascript">
$(document).ready(function(){
$.jqplot.config.enablePlugins = true;
var s1 = [<?=$nAry2?>]; //ex) 100,200,150, 300, 200, 200, 200, 200, 100, 150, 110, 120
var s2 = [<?=$nAry?>]; // ticks 숫자만큼 콤마로 구분해서 값 저장
var sg = [<?=$nAryg?>];

var ticks = ['1월', '2월', '3월', '4월', '5월', '6월', '7월', '8월', '9월', '10월', '11월', '12월'];

plot1 = $.jqplot('chart1', [s1,s2,sg], {
// Only animate if we're not using excanvas (not in IE 7 or IE 8)..
animate: !$.jqplot.use_excanvas,
axes: {
xaxis: {
renderer: $.jqplot.CategoryAxisRenderer,
ticks: ticks },
y2axis: {
pad: 0,
tickOptions: {
formatString: "%'d만원"
},
rendererOptions: {
forceTickAt0: false
},
max:2000,
numberTicks:5

},
yaxis: {
pad: 0,
tickOptions: {
formatString: "%'d건"
},
rendererOptions: {
// align the ticks on the y2 axis with the y axis.
alignTicks: true,
forceTickAt0: true
},
max:30,
numberTicks:5
}
},


series: [
{
label: '<?=$Rdate-1?>년',
yaxis: 'yaxis',
shadow: true,
renderer: $.jqplot.BarRenderer,
pointLabels: { show: true,hideZeros:true,ypadding:-1 }

},
{
label: '<?=$Rdate?>년',
yaxis: 'yaxis',
shadow: true,
renderer: $.jqplot.BarRenderer,
pointLabels: { show: true,hideZeros:true,ypadding:-1 }

},
{
label: '금액',
yaxis: 'y2axis',
shadow: true,
pointLabels: { show: true,hideZeros:true }
}

],
legend: {
show: true,
location: 'w', // compass direction, nw, n, ne, e, se, s, sw, w.
xoffset: 0, // pixel offset of the legend box from the x (or x2) axis.
yoffset: 0, // pixel offset of the legend box from the y (or y2) axis.
placement: 'outsideGrid'
},
highlighter: { show: false }
});


});</script>

twitter facebook me2day 요즘
22개(1/2페이지)
JS, HTML & CSS
번호 제목 글쓴이 조회 날짜
22 [JQUERY] jquery json 관리자 6938 2014.08.19 17:27
21 [JQUERY] [jQuery] select box 관련 관리자 14502 2014.07.02 15:33
20 [JQUERY] ajax 로딩바 이미지 생성기 관리자 9684 2014.02.13 16:40
19 [JQUERY] 반응형 이미지맵 관리자 12422 2013.12.11 17:02
18 [CSS] 투명효과, alpha, 익스10, 파폭,크롬 모두 적용 관리자 8523 2013.08.05 11:40
17 [JQUERY] jQuery live, jQuery on, ajax callback class 처리문제 관리자 8361 2013.05.23 14:40
16 [JQUERY] 카카오스토리, 카카오톡, 페이스북 모바일 연동 첨부파일 관리자 8951 2013.04.10 12:09
15 [JQUERY] ajax 한글 처리 관리자 5519 2013.04.09 20:06
14 [라이브러리소개] 제이쿼리 + CSS 이용한 튜토리얼~ [1] 관리자 8941 2013.03.07 18:20
13 [JAVASCRIPT] 글자 자르기 관리자 5486 2013.03.06 12:02
12 [JQUERY] jquery mobile 페이지 이동, 링크 관리자 7281 2013.02.20 19:43
11 [JQUERY] AJAX 심플 예제~ json 관리자 13310 2013.02.08 14:03
10 [JQUERY] [출처] jQuery로 라디오버튼의 체크여부 검사하는 방법1 관리자 6440 2013.02.04 16:42
9 [JQUERY] AJAX 기본 관리자 5317 2013.01.25 15:57
8 [JQUERY] 무한 스크롤, infinite scroll 관리자 8648 2013.01.23 18:17
7 [JQUERY] 배열 checkbox 선택여부확인 관리자 7117 2013.01.21 15:17
6 [라이브러리소개] 롤링 갤러리 관리자 5559 2013.01.21 15:17
5 [JQUERY] 간단한 div 팝업 관리자 7370 2013.01.21 15:16
>> [라이브러리소개] 제이쿼리, 그래프, 그래프 종결자 첨부파일 [1] 관리자 10905 2013.01.21 15:16
3 [CSS] CSS 줄간격, 자간, 단어 간격 등 관리자 11047 2013.01.21 15:14
많이 본 글
댓글 많은 글