<?
# 그래프 출력을 위한 데이터의 최대값및 최소값 세팅
$maxVal = 50; // 최대값 5백만
$step = 5; // 단위 5십만
$arrVal = array(25,18, 34, 46, 10, 29, 17, 38, 26, 25, 27, 39, 44, 22, 16, 43, 39, 22, 44, 18, 14, 22, 32, 45);
function showStickGraph($maxVal, $minVal, $step, $arrVal)
{
$bottomCommentHeight= 30; // 하단 설명공간 높이 픽셀값
$cntY = round($maxVal / $step); // y축 눈금개수
$unitHight = 30; // 단위 높이 픽셀값
$minVal = 0; // 최소값
$k= 10;
?>
<table cellpadding=0 cellspacing=0 border="1" >
<tr>
<!-- y축-->
<td >
<table cellpadding=0 cellspacing=0 border="1" >
<? for ($a= $maxVal; $a >= $minVal; $a -= $step){ ?>
<tr>
<td height="<?=$unitHight?>" valign="bottom" align="right">
<font size="2"><?=$a?></font>
</td>
</tr>
<?}?>
<tr>
<td height="<?=$bottomCommentHeight?>">
<font size="2">매출<br>(단위:10만)</font></td>
</tr>
</table>
</td>
<!--x축-->
<td valign="bottom">
<table cellpadding=0 cellspacing=0 border="0" >
<tr>
<? for ($i= 0; $i < 24; $i++){ ?>
<td align="center" valign="bottom">
<table cellpadding=0 cellspacing=0 border="1" >
<tr>
<td width="20" height="<?=($arrVal[$i])/$step * $unitHight ?>" bgcolor="green" valign="top" align="center">
<font size="2" color="white"><b><?=$arrVal[$i]?></b></font></td>
</tr>
<tr>
<td height="<?=$bottomCommentHeight?>" valigh="top"><font size="2"><?=($i<10)?"0$i":$i?></font></td>
</tr>
</table>
</td>
<?}?>
</tr>
</table>
</td>
</tr>
</table>
<?
}
showStickGraph($maxVal, $minVal, $step, $arrVal);
?>
게시판 목록
프로그램
| 번호 | 제목 | 글쓴이 | 날짜 | 조회 |
|---|---|---|---|---|
| 8230 | 9년 전 | 40 | ||
| 8229 | 9년 전 | 47 | ||
| 8228 |
커네드커네드
|
9년 전 | 92 | |
| 8227 | 9년 전 | 100 | ||
| 8226 | 9년 전 | 141 | ||
| 8225 | 9년 전 | 127 | ||
| 8224 | 9년 전 | 125 | ||
| 8223 | 9년 전 | 82 | ||
| 8222 |
|
9년 전 | 160 | |
| 8221 | 9년 전 | 74 | ||
| 8220 | 9년 전 | 68 | ||
| 8219 | 9년 전 | 74 | ||
| 8218 | 9년 전 | 109 | ||
| 8217 |
star3840
|
9년 전 | 90 | |
| 8216 | 9년 전 | 129 | ||
| 8215 | 9년 전 | 82 | ||
| 8214 | 9년 전 | 202 | ||
| 8213 | 9년 전 | 139 | ||
| 8212 | 9년 전 | 52 | ||
| 8211 | 9년 전 | 214 | ||
| 8210 | 9년 전 | 209 | ||
| 8209 | 9년 전 | 313 | ||
| 8208 | 9년 전 | 181 | ||
| 8207 | 9년 전 | 196 | ||
| 8206 |
|
9년 전 | 156 | |
| 8205 | 9년 전 | 142 | ||
| 8204 | 9년 전 | 106 | ||
| 8203 | 9년 전 | 196 | ||
| 8202 | 9년 전 | 122 | ||
| 8201 | 9년 전 | 161 | ||
| 8200 | 9년 전 | 126 | ||
| 8199 | 9년 전 | 174 | ||
| 8198 | 9년 전 | 151 | ||
| 8197 | 9년 전 | 130 | ||
| 8196 | 9년 전 | 507 | ||
| 8195 | 9년 전 | 132 | ||
| 8194 | 9년 전 | 262 | ||
| 8193 | 9년 전 | 128 | ||
| 8192 | 9년 전 | 156 | ||
| 8191 | 9년 전 | 111 | ||
| 8190 | 9년 전 | 107 | ||
| 8189 | 9년 전 | 161 | ||
| 8188 | 9년 전 | 100 | ||
| 8187 | 9년 전 | 118 | ||
| 8186 | 9년 전 | 128 | ||
| 8185 | 9년 전 | 284 | ||
| 8184 | 9년 전 | 80 | ||
| 8183 | 9년 전 | 305 | ||
| 8182 | 9년 전 | 134 | ||
| 8181 | 9년 전 | 106 | ||
| 8180 | 9년 전 | 670 | ||
| 8179 | 9년 전 | 471 | ||
| 8178 | 9년 전 | 275 | ||
| 8177 |
kiplayer
|
9년 전 | 276 | |
| 8176 | 9년 전 | 321 | ||
| 8175 | 9년 전 | 201 | ||
| 8174 | 9년 전 | 209 | ||
| 8173 | 9년 전 | 321 | ||
| 8172 | 9년 전 | 163 | ||
| 8171 | 9년 전 | 157 | ||
| 8170 | 9년 전 | 273 | ||
| 8169 |
커네드커네드
|
9년 전 | 237 | |
| 8168 | 9년 전 | 289 | ||
| 8167 | 9년 전 | 299 | ||
| 8166 | 9년 전 | 209 | ||
| 8165 | 9년 전 | 144 | ||
| 8164 | 9년 전 | 273 | ||
| 8163 | 9년 전 | 263 | ||
| 8162 | 9년 전 | 269 | ||
| 8161 | 9년 전 | 264 | ||
| 8160 |
|
9년 전 | 464 | |
| 8159 | 9년 전 | 378 | ||
| 8158 | 9년 전 | 192 | ||
| 8157 | 9년 전 | 336 | ||
| 8156 | 9년 전 | 251 | ||
| 8155 | 9년 전 | 231 | ||
| 8154 |
00년생용띠
|
9년 전 | 574 | |
| 8153 | 9년 전 | 201 | ||
| 8152 |
|
9년 전 | 378 | |
| 8151 | 9년 전 | 380 | ||
| 8150 | 9년 전 | 470 | ||
| 8149 |
Jangfolk
|
9년 전 | 312 | |
| 8148 | 9년 전 | 145 | ||
| 8147 | 9년 전 | 351 | ||
| 8146 | 9년 전 | 406 | ||
| 8145 | 9년 전 | 329 | ||
| 8144 | 9년 전 | 299 | ||
| 8143 | 9년 전 | 152 | ||
| 8142 | 9년 전 | 400 | ||
| 8141 | 9년 전 | 351 | ||
| 8140 | 9년 전 | 898 | ||
| 8139 | 9년 전 | 224 | ||
| 8138 |
전갈자리남자
|
9년 전 | 365 | |
| 8137 | 9년 전 | 344 | ||
| 8136 | 9년 전 | 711 | ||
| 8135 |
|
9년 전 | 759 | |
| 8134 |
PlayPixel
|
9년 전 | 470 | |
| 8133 |
|
9년 전 | 414 | |
| 8132 | 9년 전 | 428 | ||
| 8131 | 9년 전 | 781 |
댓글 작성
댓글을 작성하시려면 로그인이 필요합니다.
로그인하기