This file contains hidden or 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 | |
/** | |
* simple curl | |
* @param string $url | |
* @param array $param | |
* @return mix | |
*/ | |
function simpleCurl($url = '', $param = []) { | |
// params init |
This file contains hidden or 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 | |
use Symfony\Component\HttpFoundation\Request; | |
error_reporting(0); | |
$uri = parse_url($_SERVER['REQUEST_URI'])['path']; | |
$uri = trim($uri, '/'); | |
if (in_array($uri, [ | |
'', 'app.php', | |
'settings', 'app.php/settings', |
This file contains hidden or 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 | |
/** | |
* PHP time debug | |
* @param string $mark | |
* @param string $separate | |
* @return array | |
*/ | |
function timeDebug($mark, $echo = true, $separate) | |
{ |
This file contains hidden or 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 | |
error_reporting(E_ALL ^ E_NOTICE ^ E_WARNING); | |
date_default_timezone_set('PRC'); | |
define('APP_PATH', dirname(__FILE__)); | |
class CONFIG | |
{ | |
const EMAIL = [ | |
'host' => 'xxx.com', |
This file contains hidden or 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
package main | |
import ( | |
"fmt" | |
"time" | |
) | |
func main() { | |
ch := make(chan int, 1) |
OlderNewer