This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* @file | |
* Demo module, Basic Ajax form submit (Ajax framework). | |
*/ | |
/** | |
* Implements hook_menu(). | |
*/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
document.addEventListener('WeixinJSBridgeReady', function(){ | |
//如果执行到这块的代码,就说明是在微信内部浏览器内打开的. | |
alert('当前页面在微信内嵌浏览器中打开!'); | |
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<meta charset="utf-8"> | |
<body> | |
<script src="http://d3js.org/d3.v3.min.js"></script> | |
<script src="http://d3js.org/topojson.v1.min.js"></script> | |
<!-- I recommend you host this file on your own, since this will change without warning --> | |
<script src="http://datamaps.github.io/scripts/datamaps.world.min.js?v=1"></script> | |
<h2>Datamaps Playground</h2> | |
<p><a href="http://datamaps.github.io/">DataMaps Project Homepage</a></p> | |
<div id="container1" style="position: relative; width: 80%; max-height: 450px;"></div> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
// See https://api.drupal.org/api/drupal/core%21includes%21bootstrap.inc/function/drupal_get_path/8.4.x | |
$core_path = \Drupal::service('file_system')->realpath( | |
drupal_get_path('core', '') | |
); |