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
app: # https://github.com/tutumcloud/tutum-docker-php | |
image: tutum/apache-php:latest | |
links: | |
- mysql:db | |
- mogilefs:mogilefs | |
- elasticsearch:elasticsearch | |
- redis:redis | |
- rabbitmq:rabbitmq | |
ports: | |
- 80:80 |
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
<div style="text-align: center"> | |
<?php | |
// 45934290 - ID группы | |
$d = file_get_contents("https://api.vk.com/method/groups.getMembers?group_id=45934290&v=5.16&offset=0&count=1000&fields=photo_50"); | |
$us= json_decode($d,true); | |
foreach($us['response']['items'] as $u){ | |
echo sprintf('<img src="%s"/>',$u['photo_50']); |
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
"""Compares rethinkdb with mongo. | |
""" | |
import copy | |
import pymongo | |
import rethinkdb as r | |
import time | |
mc = pymongo.Connection() | |
rc = r.connect() |
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
location ~* ^/secure/ { | |
# sectoken=SUPERKEY | |
set $tokenheader $http_sectoken; | |
if ($tokenheader != "SUPERKEY") { | |
#add_header X-SUPERKEY $tokenheader; | |
return 403; | |
} | |
root /var/www/img2/images; |
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
$di['modelsMetadata'] = function () use ($config) { | |
if (PH_NOCACHE) { | |
$cache = new \Phalcon\Mvc\Model\Metadata\Memory(); | |
} else { | |
$cache = new \Phalcon\Mvc\Model\Metadata\Redis( | |
[ | |
'lifetime' => 86400, | |
'persistent' => false, | |
'host' => $config->redis->host, |
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 | |
namespace Models\Traits { | |
trait Isolation | |
{ | |
/** | |
* Поиск записей в изоляционной транзакции | |
* |
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
0452c6096a2e27d07e084421eeb8e9c45be0326cfd2791803fe2240546a1193bae87af6c99cb3def759dcaf5d258853dda3005f3fd68f5491ba24c399e0346fb90 |
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
Привет, Хайп! |
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
// Tracking cursor position in real-time without JavaScript | |
// Demo: https://twitter.com/davywtf/status/1124146339259002881 | |
package main | |
import ( | |
"fmt" | |
"net/http" | |
"strings" | |
) |
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
<!DOCTYPE html> | |
<html lang="en"> | |
<head> | |
<meta charset="UTF-8"> | |
<title>Demo</title> | |
<meta content="width=device-width, initial-scale=1.0" name="viewport"> | |
</head> | |
<body> |