sign.php 759 B

1234567891011121314151617181920212223242526272829303132333435363738394041
  1. <?php
  2. # 数据收集的配置
  3. $config['accessToken'] = array
  4. (
  5. 'url' => 'https://api.weixin.qq.com/cgi-bin/token?grant_type=client_credential',
  6. /*
  7. 1 => array
  8. (
  9. 'appid' => 'wx1bd1c3bfc6b0515e',
  10. 'secret' => '21f8ebe7b419a4920eb9b72532798523'
  11. ),
  12. # 牛游
  13. 2 => array
  14. (
  15. 'appid' => 'wx4978eeb711847a5a',
  16. 'secret' => '510645c52d352d915773999f3a3cf5c1'
  17. ),
  18. */
  19. );
  20. $config['accessToken'] += Dever::load('weixin/site-getAll');
  21. //print_r($config['accessToken']);die;
  22. # 得到当前的site
  23. if(!Dever::input('site'))
  24. {
  25. $top = Dever::load('manage/auth.getTop', 'site');
  26. if($top)
  27. {
  28. Dever::setInput('site', $top['value']);
  29. }
  30. }
  31. $config['ticket'] = 'https://api.weixin.qq.com/cgi-bin/ticket/getticket?type=jsapi&access_token=';
  32. return $config;