php - How to show graphs only in mPDF but not the tables? -
i've been using jpgraph library generate graphs in mdf. problem i'm facing don't want show table values graph. since in following example shows both. http://mpdf1.com/manual/index.php?tid=364 there way this? plase help.
thanks!
<?php include("../mpdf.php"); // must defined before including mpdf.php file define("_jpgraph_path", '../../jpgraph_5/src/'); // change these if necessary name of font files can access jpgraph define("_ttf_font_normal", 'arial.ttf'); define("_ttf_font_bold", 'arialbd.ttf'); $mpdf=new mpdf(); // must set allow mpdf parse table data $mpdf->usegraphs = true; $html = ' <table id="tbl_1"><tbody> <tr><td></td><td><b>female</b></td><td><b>male</b></td></tr> <tr><td>35 - 44</td><td><b>4</b></td><td><b>2</b></td></tr> <tr><td>45 - 54</td><td><b>5</b></td><td><b>7</b></td></tr> <tr><td>55 - 64</td><td><b>21</b></td><td><b>18</b></td></tr> <tr><td>65 - 74</td><td><b>11</b></td><td><b>14</b></td></tr> <tr><td>75 - 84</td><td><b>10</b></td><td><b>10</b></td></tr> <tr><td>85 - 94</td><td><b>2</b></td><td><b>1</b></td></tr> <tr><td>95 - 104</td><td><b>1</b></td><td><b></b></td></tr> <tr><td>total</td><td>54</td><td>52</td></tr> </tbody></table> <jpgraph table="tbl_1" type="bar" title="new subscriptions" label-y="% patients" label-x="age group" series="cols" data-row-end="-1" show-values="1" width="600" legend-overlap="1" hide-grid="1" hide-y-axis="1" /> '; $mpdf->writehtml($html); $mpdf->output(); exit; ?>
change table this:
<table id="tbl_1" style="display:none">
Comments
Post a Comment