jquery实现问卷调查投票结果百分比柱状图表效果代码

代码语言:html

所属分类:图表

代码描述:jquery实现问卷调查投票结果百分比柱状图表效果代码

代码标签: 投票 结果 百分比 柱状 图表 效果

下面为部分代码预览,完整代码请点击下载或在bfwstudio webide中打开

<!DOCTYPE html>
<html>
<head>
    <meta charset="UTF-8">

    <script type="text/javascript" src="//repo.bfw.wiki/bfwrepo/js/jquery-3.2.1.min.js"></script>
    <script>

        var bar = function (id, title, data) {
            //展示的id
            this.id = '';

            //标题
            this.title = '';

            //数据
            this.data = '';

            //宽
            this.width = 500;

            //背景图片位置
            this.bgimg = 'data:image/gif;base64,R0lGODlhAwDPAff/ALz3RdqlD6vyOP2Xoe+TBBmtCwOnDP+vsf/UFTSC3ZSVla1VCyOzC1vG9CoqKl298f/yWP/gLWbi/CMjIxO7Dj6z7v2OmmXe+/KpF0fIDSPGDkVDQ3p6e8yLDSqS409NTQSYCvOqAv/pQTIyMtWcDjW9DOVH8fxzhZwCrcn6T7psDHNzdBlyzAi1Dv6vtv2krf11mvKsJpkBtJXrK2jr/v/nO/93dzKj6oGBgWwAmFis6+tR+PNa/TKN4aABuowBrTJ32Vuy7bQExqUEtf/dJWRjYxFhuV1ZWqsCwbcCyHwAo2HF9DuJ4J6fn2ndEWLX+ZcCq3ziHc8n21ZVVSKYA8oe1a0FvT6Q466uromKiv6VnTJ+3P6prf/ZHtw86WpqamPR+KTvONUx4vW+NRVpwhWTBf/0YRNlvf/tTSmi6v2vuCukAxdtx//iMa8CwxBft+lDZ2jaD/54nvlujfp1jampqf/OC/+KinBub2TYDrJeCxGkChRmv/fBFO+XFF7R9+tJbVvTDtIe3YvqHRZrxPjNKO5QdIgBmVvL9fS0FBWdCB2dBfbAKP6DhxGOBSG7DPyEkf6Mk/+YmNse5mDWDmLbB+c88sMG1dYn4vlskXHhEXrlEftwlf6kp/t9kKampj+i6fbCNBGuDI/oK9sx5/5mamfn/T7CDb91DL4Ez/nRKPW+LCy4DDyc5/tSZPpTbDiq7P1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wwjTWcqPGC9ps24wkdxyTSyPGRHKLIZCccI4nJwBCBx24zDEHHPQmq+yyzkILAxcucPKCC5n8O80LanBDsDZ3SNJMI7kcc0skxpwAiSEneHLOu4DIiwu9cNhr00B1fPIJPwookEU66eDAAQfsrLACHl/EXEQR7axj8wYb/IIMMvToossIDjjwjks5n8SVxzaJZcrSFzQNxtNLRP3A1OUEEYQOWNdzxdZMdJ1AAlsAAUTYQCRQTDEepI0b0o6xB1wKz8Qdxtyj1B3F3U7kvU8vvbSq4HcLBgQeOAiEm2N4GY44QsXiEbL9VYVJYMjDDpSbYLkXmIuhuRScV+G5FUOEjgIKUNhiiz7eeHPINtvoc8ghMkABRZuO/yMnBLiLoHsbEURARBdduIPA8HYUL400+HzzjT8hNJ9MMvcQQIA90sfjhx/5xJApsrXLtKwczh7ARSedDKDF+RZYoEX6A6S/vgU2oCN/KaX0E0ss87jiijyvvAJPNtmQ17zoFRAAOw==';

            //动画速度
            this.speed = 1000;

            //投票总数
            var num_all = 0;
            this.show = function () {
                //添加一个table对象
                $("#"+this.id).append("<table width='"+this.width+"' cellpadding=0 cellspacing=6 border=0 style='font-size:12px;' ></table>")

                $("#"+this.id+" table").append("<tr><td colspan=3 align='center' ><span style='fo.........完整代码请登录后点击上方下载按钮下载查看

网友评论0