V2EX = way to explore
V2EX 是一个关于分享和探索的地方
现在注册
已注册用户请  登录
V2EX  ›  lslqtz  ›  全部回复第 202 页 / 共 243 页
回复总数  4843
1 ... 198  199  200  201  202  203  204  205  206  207 ... 243  
2016-06-21 14:22:09 +08:00
回复了 heat 创建的主题 云计算 ECS 无故被初始化... 阿里云到底想干嘛?!
@julyclyde 什么叫没啥问题??
楼主发工单的目的不是求阿里云重置的,而是让阿里云解决问题的。
然后重置了数据谁赔?
2016-06-21 14:20:49 +08:00
回复了 heat 创建的主题 云计算 ECS 无故被初始化... 阿里云到底想干嘛?!
@aliyun123 我的网站即将迁出阿里云了,呵呵。
2016-06-21 12:32:31 +08:00
回复了 cloudinsight 创建的主题 推广 盖楼送 Tee,体验 Ci 送京东卡!开发板! Xbox!
挤挤
2016-06-21 10:22:04 +08:00
回复了 whoops 创建的主题 Linux ubuntu 下的 chrome 经常导致卡死,求老司机带带路啊。
我就不想说我的 Chrome 天天掉 cookie 了, Firefox 大法好!
server_name www.loliwiki.org 下的 /var/www/html 已改为 /var/www/wiki 。。
日了,配置文件突然发现写错了。。
附上本人配置文件。

#user nobody;
worker_processes 1;

events {
worker_connections 1024;
}

http {
include mime.types;
default_type application/octet-stream;

sendfile on;
keepalive_timeout 600;
client_max_body_size 128m;
server_names_hash_bucket_size 64;

fastcgi_connect_timeout 300s;
fastcgi_send_timeout 300s;
fastcgi_read_timeout 300s;
fastcgi_buffer_size 128k;
fastcgi_buffers 8 128k;
fastcgi_busy_buffers_size 256k;
fastcgi_temp_file_write_size 256k;
fastcgi_intercept_errors on;

gzip on;
gzip_comp_level 9;
gzip_types text/plain text/css application/javascript;

server {
listen 80;
return 403;
}

server {
listen 80;
server_name loli.wiki www.loli.wiki loliwiki.cn www.loliwiki.cn loliwiki.cc www.loliwiki.cc loliwiki.org www.loliwiki.org;
return 301 https://www.loliwiki.org$request_uri;
}

server {
listen 443 ssl http2;
server_name www.loliwiki.org;
index index.php index.htm index.html;
root /var/www/wiki;

ssl_prefer_server_ciphers on;
ssl_session_cache shared:SSL:10m;
ssl_protocols TLSv1 TLSv1.1 TLSv1.2;
ssl_ciphers EECDH+CHACHA20:EECDH+AES128:RSA+AES128:EECDH+AES256:RSA+AES256:EECDH+3DES:RSA+3DES:!MD5;
ssl_certificate /usr/local/nginx/conf/1.crt;
ssl_certificate_key /usr/local/nginx/conf/1.key;
ssl_ct on;
ssl_ct_static_scts /usr/local/nginx/conf/sct1;

location / {
try_files $uri $uri/ /index.php?$args;
if (-f $request_filename) {
break;
}
set $supercache_file '';
set $supercache_uri $request_uri;
set $supercache 1;
set $ihttp_host '';
if ($request_method = POST) {
set $supercache 0;
}
set $qs 0;
if ($query_string) {
set $qs 1;
}
if ($query_string ~* "^utm_source=([^&]+)&utm_medium([^&]+)&utm_campaign=([^&]+)(&utm_content=([^&]+))?$") {
set $qs 0;
set $supercache_uri $document_uri;
}
#deactivate on high load
if ($qs = 1) {
set $supercache 0;
}
if ($http_cookie ~* "comment_author_|wordpress|wp-postpass_" ) {
set $supercache 0;
}
if ($http_user_agent ~* '(iphone|ipod|aspen|incognito|webmate|android|dream|cupcake|froyo|blackberry9500|blackberry9520|blackberry9530|blackberry9550|blackberry 9800|webos|s8000|bada)') {
set $ihttp_host '-mobile';
}
if ($supercache = 0) {
set $supercache_uri '';
}
if ($supercache_uri ~ ^(.+)$) {
set $supercache_file /var/www/html/wp-content/cache/supercache/$http_host$1/index${ihttp_host}.html;
}
if (-f $document_root$supercache_file) {
#rewrite ^(.*)$ $supercache_file break;
rewrite ^ $supercache_file last;
}
if (!-e $request_filename) {
rewrite . /index.php last;
}
}
rewrite /wp-admin$ $scheme://$host$uri/ permanent;

location ~ /\.ht {
deny all;
}
location ~ \.(gif|jpg|png|htm|html|css|js|ico)$ {
expires 30d;
}
location ~ .*\.(php|php5)?$ {
fastcgi_pass unix:/var/run/phpfpm.sock;
fastcgi_index index.php;
include fastcgi.conf;
}
}

server {
listen 80;
server_name hardware.name www.hardware.name hardwareunion.com;
return 301 http://www.hardwareunion.com$request_uri;
}

server {
listen 80;
server_name www.hardwareunion.com;
index index.php index.htm index.html;
root /var/www/html;

location / {
try_files $uri $uri/ /index.php?$args;
if (-f $request_filename) {
break;
}
set $supercache_file '';
set $supercache_uri $request_uri;
set $supercache 1;
set $ihttp_host '';
if ($request_method = POST) {
set $supercache 0;
}
set $qs 0;
if ($query_string) {
set $qs 1;
}
if ($query_string ~* "^utm_source=([^&]+)&utm_medium([^&]+)&utm_campaign=([^&]+)(&utm_content=([^&]+))?$") {
set $qs 0;
set $supercache_uri $document_uri;
}
#deactivate on high load
if ($qs = 1) {
set $supercache 0;
}
if ($http_cookie ~* "comment_author_|wordpress|wp-postpass_" ) {
set $supercache 0;
}
if ($http_user_agent ~* '(iphone|ipod|aspen|incognito|webmate|android|dream|cupcake|froyo|blackberry9500|blackberry9520|blackberry9530|blackberry9550|blackberry 9800|webos|s8000|bada)') {
set $ihttp_host '-mobile';
}
if ($supercache = 0) {
set $supercache_uri '';
}
if ($supercache_uri ~ ^(.+)$) {
set $supercache_file /var/www/html/wp-content/cache/supercache/$http_host$1/index${ihttp_host}.html;
}
if (-f $document_root$supercache_file) {
#rewrite ^(.*)$ $supercache_file break;
rewrite ^ $supercache_file last;
}
if (!-e $request_filename) {
rewrite . /index.php last;
}
}
rewrite /wp-admin$ $scheme://$host$uri/ permanent;

location ~ /\.ht {
deny all;
}
location ~ \.(gif|jpg|png|htm|html|css|js|ico)$ {
expires 30d;
}
location ~ .*\.(php|php5)?$ {
fastcgi_pass unix:/var/run/phpfpm.sock;
fastcgi_index index.php;
include fastcgi.conf;
}
}
}
2016-06-20 11:40:22 +08:00
回复了 BBOO 创建的主题 PHP php 如何高效率的判断远程图片是否存在
<?php
error_reporting(0);
header('content-type:application/json');
$data='vssfafsa=dgastgdagda&xfafafaf=tgfdfdsafa';
$opts=array(
'http'=>array(
'method'=>'POST',
'header'=>"Content-type:application/x-www-form-urlencoded\r\nContent-length:".strlen($data),
'content'=>$data
));
file_get_contents('http://www.baidu.com',false,stream_context_create($opts));
if ($http_response_header[0] == 'HTTP/1.1 302 Moved Temporarily') {
echo '{"code":200}';
} else {
echo '{"code":403}';
}
?>
这样?
2016-06-20 11:39:26 +08:00
回复了 BBOO 创建的主题 PHP php 如何高效率的判断远程图片是否存在
file_get_contents get_headers
2016-06-20 10:40:11 +08:00
回复了 iugo 创建的主题 程序员 民间布道: 让 Web 服务使用 HTTPS
@BearTher 啥,你和 cn.com 比好记?
国外还有 com.sb 呢。。
1 ... 198  199  200  201  202  203  204  205  206  207 ... 243  
关于   ·   帮助文档   ·   博客   ·   API   ·   FAQ   ·   实用小工具   ·   2826 人在线   最高记录 6679   ·     Select Language
创意工作者们的社区
World is powered by solitude
VERSION: 3.9.8.5 · 47ms · UTC 14:24 · PVG 22:24 · LAX 06:24 · JFK 09:24
Developed with CodeLauncher
♥ Do have faith in what you're doing.