public function _enable() { $ret=new stdClass(); $ret->success=true; $r= new JTFundPrice($_SESSION['login_user_id']); $r->select( $_GET['id'] ); $r->data['enable'] = $_GET['enable']; $r->update(); die( json_encode($ret) ); }
<?php require_once '../jasonwang826/jasonwang826.inc'; $ret = array(); $fp = new JTFundPrice(); $rs = $fp->all(); foreach ($rs as $d) { $ret[] = (object) array('date' => $d->date, 'dateCol' => $d->date, 'val' => $d->price); } echo json_encode(array_reverse($ret));
<div class="faq-tabs-change right"> <div id="marquee_prev_btn" class="btn btn-faq-tabs-prev faq-tabs-btn left"> <i class="fa fa-caret-down"></i> </div> <div id="marquee_next_btn" class="btn btn-faq-tabs-next faq-tabs-btn left"> <i class="fa fa-caret-up"></i> </div> </div> </div> </div> <div class="cnt editorDF"> <div id="chartdiv" style="width:90%; height:600px; margin:auto;"></div> <div class="net_asset_value-cnt cf"> <div class="col-2"> <?php $fp = new JTFundPrice(); $rsFundPrice = $fp->all(20, true); $half = ceil(sizeof($rsFundPrice) / 2); ?> <table class="table1"> <tr> <th>日期</th> <th>淨值</th> </tr> <?php for ($i = 0; $i < $half; $i++) { ?> <tr> <td><?php echo $rsFundPrice[$i]->date; ?>
<li class="banner" style="background-image: url('<?php echo $r->fpath; ?> ');"><a href="<?php echo $r->link; ?> " class="index-banner hide_txt">more info</a></li> <? } ?> </ul> </section> <main class=""> <section id="netAssetValueBar" class="fullbg row0 net_asset_value"> <?php $fp = new JTFundPrice(); $fp->last(); ?> <div class="wrapper cf"> <div class="col-4 txt-6">Today's Net Asset Value</div> <div class="col-4"> <label for="" class="net_asset_value-label col "> <span class="net_asset_value-label-bg"></span> <span class="net_asset_value-label-cnt txt-6_1">基金淨值日</span> </label> <div class="net_asset_value-txt col txt-6"><?php echo JDate::date_format($fp->data['date'], 'Y/m/d'); ?> </div> </div> <div class="col-4">